Name: [3253] gasto
Member: 83 months
Authored: 41 videos
Description: C/C++ and python programmer. Some knowledge of graphic design too. Interested in Game Artificial Intelligence and Artificial Life. Currently studying(by myself)too many things to be worth the mention. Happy to contribute to the 'help-without-compensation-asked' community. I hope every one that r ...

C tutorial - C syntax , part II - [ID:547] (6/8)

in series: C programming tutorial.

video tutorial by gasto, added 03/08

Series ID: 138 Video ID: 547

The confusing static keyword is demystified, by defining variables in different places (outside every function or in a block). We start to see the disadvantages and stingy nature of the C tokens. Static defined inside a block refers to the static aspect of its duration, while static defined outside every function refers to the internal-linkage aspect of its linkage. Auto storage class specifier is used for documentation purposes mostly. We also dive into the difference between syntax and semantic, with a clear example.

Visit the C Console Programming video series for updates on C programming from me.

// Csyntax.cpp : Defines the entry point for the console application.
//

#include "stdafx.h"

extern short shortnum;
void doSomething(void);

int _tmain(int argc, _TCHAR* argv[])
{
	//extern short shortnum;
	char letter = 't';
	char * string = "hello everyone";
	float floatnum = 4.45462;
	int num = 3;
	short assignment = shortnum;
	short shortnum = 2;
	doSomething();
	doSomething();

	if (num <= 2) {shortnum = 4;}
	printf("%d \n", shortnum);
	
	
	getchar();
	return 0;
}

void doSomething(void){
	int variable = 1; //this is initialized once.
	printf("%d  %d\n", shortnum , variable);
	variable++; // variable = variable+1;

}

Got any questions?

Get answers in the ShowMeDo Learners Google Group.

Video statistics:

  • Video's rank shown in the most popular listing
  • Video plays: 1458 (since July 30th)
  • Plays in last week: 0
  • Published: 80 months ago

Thank-yous, questions and comments

If this video tutorial was helpful please take some time to say thank-you to the authors for their hard work. Feel free to ask questions. Let the author know why their video tutorial was useful - what are you learning about? Did the video tutorial save you time? Would you like to see more?

You may also want to see our ShowMeDo Google Group to speak to our active users and authors.

Your email address will not be published.

Show some quick comments >>








All comments excluding tick-boxed quick-comments

Your video has been edited. This is an automatic post by ShowMeDo.


8. joe oettinger Sun, 28 Feb 2010 10:41

At this point my contribution will have to be thanks and any constructive criticism.

I see from your biographical info that you are "Happy to contribute to the 'help-without-compensation-asked' community. I hope every one that reads this contributes something back as well."

I'm retired, but I am giving some "help-without-compensation", by spending 4 hours a week teaching a Chicano fellow I've met up here in Michigan to speak better English.

I saw a movie once where one guy helped another and told him to "pass it on". Maybe that's the idea.

Thanks for pointing out a the C static initialization pitfall.

Joe


7. anonymous Mon, 12 Oct 2009 16:07

very Good video tutorial. Please keep posting! Thank you.


6. anonymous Thu, 30 Jul 2009 14:49

this is super awsome ! keep up the good work guy =)


5. anonymous Sat, 25 Jul 2009 00:32

informative


4. anonymous Tue, 07 Oct 2008 14:24

thanks..

Please tond too much take time while explaning.. because video will become lenghty..

from developing countries it takes time to load lengithy vedio

rest is good


Will be very soon, updated with 2 new entries.


very good and clear tutorial! thanks , i hope it will be continued


Video published, thanks for contributing to ShowMeDo


Showmedo is a peer-produced video-tutorials and screencasts site for free and open-source software (FOSS)- with the exception of some club videos, the large majority are free to watch and download.

how to help » about » faq »

Educating the Open-source Community With Showmedo

Although as important as the software it supports, education and documentation are relatively neglected in the Open-source world. Coders love to code, and explaining how best to use or improve the software tends to be deferred or even sidelined.

At Showmedo we believe the community can play a vital role here and also say thanks for the tools and software that make our lives easier. If you have a piece of software you love or a programming langugage you are enthusiastic about, why not make a screencast showing others how to use it? All the stuff you wish you'd been told, the tips, tricks, insights that would have saved you time and frustration.

Screencasting is easier than you think, and we're happy to help you. You can emailus for advice or just use some of the how-to screencasts on the site. This screencasting learning-pathis a good place to start.

Kudos and Thanks for gasto

Content

Feedback

Showmedo's development is fairly rapid and bugs will inevitably creep in. If you have any problems please drop us a line using the contact address below. Likewise, any suggestions for improvements to the site are gratefully received.

feedback@showmedo.com