Pointer Arithmetic Practice
Oppgave
Swipe to start coding
- Create a pointer that points to the first variable.
- Find the distance between memory locations of this two variables.
- Using the pointer arithmetic move the pointer to the location of the second variable.
- Modify the value of dereferenced pointer to
50
and output the second variable.
Løsning
solution.cpp
Alt var klart?
Takk for tilbakemeldingene dine!
Seksjon 2. Kapittel 2
single
Spør AI
Spør AI
Spør om hva du vil, eller prøv ett av de foreslåtte spørsmålene for å starte chatten vår
Awesome!
Completion rate improved to 5.88
Pointer Arithmetic Practice
Sveip for å vise menyen
Oppgave
Swipe to start coding
- Create a pointer that points to the first variable.
- Find the distance between memory locations of this two variables.
- Using the pointer arithmetic move the pointer to the location of the second variable.
- Modify the value of dereferenced pointer to
50
and output the second variable.
Løsning
solution.cpp
Alt var klart?
Takk for tilbakemeldingene dine!
Awesome!
Completion rate improved to 5.88Seksjon 2. Kapittel 2
single