C

Asked • 05/25/19

typedef struct vs struct definitions?

I'm a beginner in C programming, but I was wondering what's the difference between using `typedef` when defining a structure versus not using `typedef`. It seems to me like there's really no difference, they accomplish the same goal. struct myStruct{ int one; int two; };vs. typedef struct{ int one; int two; }myStruct;

1 Expert Answer

By:

Still looking for help? Get the right answer, fast.

Ask a question for free

Get a free answer to a quick problem.
Most questions answered within 4 hours.

OR

Find an Online Tutor Now

Choose an expert and meet online. No packages or subscriptions, pay only for the time you need.