Saltar al contenido principal
LibreTexts Español

31.4: Capítulo 8

  • Page ID
    81896
  • \( \newcommand{\vecs}[1]{\overset { \scriptstyle \rightharpoonup} {\mathbf{#1}} } \) \( \newcommand{\vecd}[1]{\overset{-\!-\!\rightharpoonup}{\vphantom{a}\smash {#1}}} \)\(\newcommand{\id}{\mathrm{id}}\) \( \newcommand{\Span}{\mathrm{span}}\) \( \newcommand{\kernel}{\mathrm{null}\,}\) \( \newcommand{\range}{\mathrm{range}\,}\) \( \newcommand{\RealPart}{\mathrm{Re}}\) \( \newcommand{\ImaginaryPart}{\mathrm{Im}}\) \( \newcommand{\Argument}{\mathrm{Arg}}\) \( \newcommand{\norm}[1]{\| #1 \|}\) \( \newcommand{\inner}[2]{\langle #1, #2 \rangle}\) \( \newcommand{\Span}{\mathrm{span}}\) \(\newcommand{\id}{\mathrm{id}}\) \( \newcommand{\Span}{\mathrm{span}}\) \( \newcommand{\kernel}{\mathrm{null}\,}\) \( \newcommand{\range}{\mathrm{range}\,}\) \( \newcommand{\RealPart}{\mathrm{Re}}\) \( \newcommand{\ImaginaryPart}{\mathrm{Im}}\) \( \newcommand{\Argument}{\mathrm{Arg}}\) \( \newcommand{\norm}[1]{\| #1 \|}\) \( \newcommand{\inner}[2]{\langle #1, #2 \rangle}\) \( \newcommand{\Span}{\mathrm{span}}\)\(\newcommand{\AA}{\unicode[.8,0]{x212B}}\)

    Problema 1: Solución

    float *fptr;
    

    Problema 3: Solución

    c es un carácter sin signo, una variable de ocho bits (un byte). p es un puntero a un carácter sin signo, lo que significa que contiene la dirección de una variable que es un carácter sin signo (como c). p podría tener dos, cuatro u ocho bytes de tamaño, dependiendo del sistema operativo.

    Problema 5: Solución

    & es la “dirección del” operador. Devuelve la dirección de la variable asociada. * es el operador de desreferenciación. Devuelve el valor que se encuentra en la dirección de memoria referenciada por la variable asociada.

    Problema 7: Solución

    Esto multiplica b por el valor al que hace referencia c (es decir, c es un puntero). Puede ser más claro mostrar explícitamente la desreferencia del puntero:

    a = b * (*c);
    

    This page titled 31.4: Capítulo 8 is shared under a CC BY-NC-SA 4.0 license and was authored, remixed, and/or curated by James M. Fiore via source content that was edited to the style and standards of the LibreTexts platform; a detailed edit history is available upon request.