Header Ads

ad728
  • C Program to Store Information(Name,Roll no and Marks) of a Student Using Structure

    INPUT NAME ROLL NO AND MARKS OF STUDENT AND                           PRINT USING STRUCTURE

    #include<stdio.h>
    #include<string.h.
    struct student
    {
    char name[200];
    int rollno;
    float marks;
    };
    int main()
    {
    struct student obj;
    strcpy(obj.name,"Anas");
    obj.rollno=075;
    obj.marks=88.4;
    printf("Name=%s\n",obj.name);
    printf("Rollno=%d\n",obj.rollno);
    printf("Marks=%f\n",obj.marks);
    }

    No comments

    C Program to Store Information(Name,Roll no and Marks) of a Student Using Structure

    INPUT NAME ROLL NO AND MARKS OF STUDENT AND                           PRINT USING STRUCTURE #include<stdio.h> #include<string.h...

    Post Top Ad

    ad728

    Post Bottom Ad

    ad728