Semester : S1 and S2
Subject : Computer Programming
Year : 2018
Term : MARCH
Branch : BIOTECHNOLOGY
Scheme : 2015 Full Time
Course Code : CS 100
Page:9
Output:
(11100 7600161 values example
Name:
Subject :
Percentage : 86.500000;
Union record2 values example
Name: Mani
Subject : Physics
Percentage : 99.500000
8.A pointer is a variable whose value is the address of another variable, i.e., direct address of the
memory location. Like any variable or constant, you must declare a pointer before using it to
store any variable address. The general form of a pointer variable declaration is -
type *var-name;
Here, type is the pointer's base type; it must be a valid C data type and var-name is the name of
the pointer variable.the asterisk is being used to designate a variable as a pointer. So 'ptr' is
apointer of type integer 9.
call by value call by reference
n call by value, a copy of actual In call by reference, the location arguments is passed to formal
address) of actual arguments is passed arguments of the called function and any to formal arguments
of the called change made to the formal arguments in function. This means by accessing the the called
unction have no effect on the addresses of actual arguments we can values of actual arguments in the
alling alter them within from the called function. function.
n call by value, actual arguments will In call by reference, alteration to actual