\* C Program using structure to create student record and display them *\
# include < stdio.h >
# include < conio.h >
struct stud
{
int roll_no ;
char stud_name[20] ;
int std ;
} ;
void student( struct stud s )
{
printf(" Student details:\n") ;
printf("--------------------------\n" ) ;
printf(" Roll Number : %d",s.roll_no ) ;
printf("\n Name : %s",s.stud_name ) ;
printf("\n Std : %d",s.std ) ;
}
int main( )
{
printf(" Enter Student Details\n" ) ;
printf("--------------------------\n") ;
printf(" Roll Number : ") ;
scanf("%d",&s.roll_no) ;
printf(" Name : ") ;
scanf("%s",s.stud_name) ;
printf(" Std. : ") ;
scanf("%d", &s.std ) ;
printf("--------------------------\n") ;
student(s) ;
return 0 ;
}