Notice: This page requires JavaScript to function properly.
Please enable JavaScript in your browser settings or update your browser.
Lära Challenge: Multi-level Pointers | Dynamic Allocation and Multi-level Pointers
C Pointers Mastery

bookChallenge: Multi-level Pointers

Uppgift

Swipe to start coding

Write a function that sets the integer value pointed to by a double pointer to 10.

  • Define a function void set_to_ten(int **pp);.
  • The function must set the value of the integer pointed to by *pp to 10.
  • Do not print, input, or allocate memory in this function; only set the value.

Lösning

Var allt tydligt?

Hur kan vi förbättra det?

Tack för dina kommentarer!

Avsnitt 3. Kapitel 3
single

single

Fråga AI

expand

Fråga AI

ChatGPT

Fråga vad du vill eller prova någon av de föreslagna frågorna för att starta vårt samtal

close

bookChallenge: Multi-level Pointers

Svep för att visa menyn

Uppgift

Swipe to start coding

Write a function that sets the integer value pointed to by a double pointer to 10.

  • Define a function void set_to_ten(int **pp);.
  • The function must set the value of the integer pointed to by *pp to 10.
  • Do not print, input, or allocate memory in this function; only set the value.

Lösning

Switch to desktopByt till skrivbordet för praktisk övningFortsätt där du är med ett av alternativen nedan
Var allt tydligt?

Hur kan vi förbättra det?

Tack för dina kommentarer!

Avsnitt 3. Kapitel 3
single

single

some-alt