Lesson 20 of 23

Pointers, Arrays

10 min 35 XP

Array-യുടെ പേര് അതിന്റെ ആദ്യ ഘടകത്തിന്റെ address ആണ്, അതിനാൽ a[i]-ഉം *(a + i)-ഉം ഒന്നുതന്നെ. p++ അടുത്ത ഘടകത്തിലേക്ക് നീങ്ങുന്നു (int-ന് 4 bytes മുന്നോട്ട്).

Example: edit me and press Run

Output Loading C (first time takes a few seconds)
Press Run to see the result here.

Challenge

+35 XP

n-ഉം n സംഖ്യകളും വായിക്കൂ. Pointers മാത്രം ഉപയോഗിച്ച് (a[i] അല്ല; *(a + i) അല്ലെങ്കിൽ p++) array അതേ സ്ഥലത്ത് തിരിച്ചിട്ട് print ചെയ്യൂ. Input: 5 1 2 3 4 5 Output: 5 4 3 2 1

Output Loading C (first time takes a few seconds)
Press Run to see the result here.