2078 10

BIT102 ยท 2078 ยท 5 marks

Write a program to find smallest element of an array using a pointer.

Write a program to find smallest element of an array using a pointer. [5]

C ProgrammingChapter 8: Pointers and Dynamic MemoryFinding smallest element using pointers

--- --- Concept Description ------ ptr = arr Pointer assigned the base address of the array ptr Dereferences pointer to get the value at that address ptr++ Moves pointer to the next array element (next memory location) smallest Stores the minimum value found so far --- 1. Pointer ptr is initializ...