Comment on Tutorial - Pointers to Structures example program in C By Charles



Comment Added by : niru

Comment Added at : 2012-07-21 07:26:27

Comment on Tutorial : Pointers to Structures example program in C By Charles
#include<stdio.h>
void main(){
struct tag{
int a;
char *name;
};

struct tag t1;
printf("enter num and name\n");
scanf("%d %s",&t1.a,t1.name);
printf("%d %s",t1.a,t1.name);
}

whats wrong with the above program?


View Tutorial



Subscribe to Tutorials

Related Tutorials

Program using concept of byte long short and int in java

Update contents of a file within a jar file

Tomcat and httpd configured in port 8080 and 80

Java File

Java String

Count number of vowels, consonants and digits in a String in Java

Reverse a number in Java

Student marks calculation program in Java

Handling Fractions in Java

Calculate gross salary in Java

Calculate average sale of the week in Java

Vector in Java - Sample Program

MultiLevel Inheritance sample in Java

Multiple Inheritance sample in Java

Java program using Method Overriding

Archived Comments

1. thanks
View Tutorial          By: nitin at 2010-03-29 01:02:57

2. i am not sure of this line(depends on your jvm) ,
View Tutorial          By: vpeddi at 2010-03-20 07:20:19

3. Hi Steve.
I have two applications; 1 listen

View Tutorial          By: Victor at 2010-08-18 01:22:49

4. i have created the main class to run the five clas
View Tutorial          By: Muraya at 2014-04-08 14:48:36

5. This tutorial is really Good and enhance my desire
View Tutorial          By: Yasin at 2011-07-09 10:04:57

6. Good One..
View Tutorial          By: Subhranil Mukherjee at 2015-03-11 07:22:18

7. how to get this list to be alphabetically correct?
View Tutorial          By: Vincent at 2011-06-14 07:36:58

8. thank you sir, please provide me string array in d
View Tutorial          By: ravi gupta at 2012-01-17 17:04:33

9. all of codes of t-C++ ide, it is applicable to use
View Tutorial          By: jonard at 2009-06-05 20:41:39

10. Very good example .. i ve written this program . P
View Tutorial          By: gomz at 2011-09-26 12:33:54