Saltar al contenido principal
LibreTexts Español

6.3: Ejercicios

  • Page ID
    81878
  • \( \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}}\)

    Ejercicio\(\PageIndex{1}\)

    Escribe el código para declarar una matriz de 12 números reales de precisión única.

    Ejercicio\(\PageIndex{2}\)

    Escribe el código para declarar una matriz de 15 enteros con signo de ocho bits.

    Ejercicio\(\PageIndex{3}\)

    Supongamos que se ha declarado una matriz de 100 números reales de doble precisión y se nombra puntos. Escribe el código para imprimir el primer ítem de puntos. Además, escribe el código para establecer el último ítem de puntos en 0.0.

    Ejercicio\(\PageIndex{4}\)

    Declare una cadena llamada mamífero e inicializarla a la palabra marmota.

    Ejercicio\(\PageIndex{5}\)

    ¿Ves algún problema potencial con este fragmento de código de inicialización? Si es así, explique los problemas y cómo podrían corregirse.

    char bird;
    
    bird[0]=’s’
    bird[1]=’w’
    bird[2]=’a’
    bird[3]=’l’
    bird[4]=’l’
    bird[5]=’o’
    bird[6]=’w’ 
    

    This page titled 6.3: Ejercicios 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.