473,387 Members | 1,464 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,387 software developers and data experts.

hello, i use code ::block 10.5 what todo when i see expected indentifier before while

I would like to know where i see expected identifier before while;
Expand|Select|Wrap|Line Numbers
  1. #include <stdio>
  2. #include <stdlib>
  3. int NombreEntier =0;
  4. while (NombreEntier !=47)
  5. {
  6.   printf ("taper le Nombre 47!");
  7.   scanf("%d", &NombreEntier);
  8. }
When it build i see expected identifier before while or ( before While . Can some one help me?
Jan 4 '11 #1
1 1749
Oralloy
988 Expert 512MB
charles,

Your problem is that your while loop is not embedded in a function, like "main".

Try something like this:
Expand|Select|Wrap|Line Numbers
  1. #include <stdio>
  2. #include <stdlib>
  3. int main()
  4. {
  5.   int NombreEntier =0;
  6.   while (NombreEntier !=47)
  7.   {
  8.     printf ("taper le Nombre 47!");
  9.     scanf("%d", &NombreEntier);
  10.   }
  11.   return 0;
  12. }
Cheers!
Oralloy
Jan 4 '11 #2

Sign in to post your reply or Sign up for a free account.

Similar topics

699
by: mike420 | last post by:
I think everyone who used Python will agree that its syntax is the best thing going for it. It is very readable and easy for everyone to learn. But, Python does not a have very good macro...
0
by: Ramprasad Ramamurthy | last post by:
Hi, Could you please share the issues you faced when using any of application code block that Microsfot provides in your projects. It would be great if you could share some of the performance and...
8
by: aundro | last post by:
Hello all, I was wondering whether I could do something like: --snip-- MyType.prototype.myProp = {var xxx = 'this is a string'; xxx.substring(4);} --snip--
5
by: Bill Priess | last post by:
Hey gang, Ok, I'm stumped on this one... I am using the using statement to wrap a SqlDataAdapter that I am using to fill a DataTable. Now, what I need to know is, just how much block-scope...
3
by: Ben | last post by:
Hi There I am doing some unit testing at the moment, and the majority of the leg work involves taking two objects (expected vs actual) and verifying that their properties are equal. The objects...
3
by: E | last post by:
I have 2 aspx pages... neither of which do anything out of the ordinary. One of the pages automatically generates this block of code when viewed at the client:...
0
by: Lloyd Dupont | last post by:
I have created a templated control. I used for a while and the I decided to put some internatioanlized string instead of hardcoded string into the template. and then my page fail at runtime when...
8
by: Tim_Mac | last post by:
hi, i have a group of individual radio buttons that i am running some client-side code on for the onClick event. there is a URL generated by a code block inside the onClick attribute. the...
1
by: navisingh | last post by:
I have a HTML page with a block of text encased in <code> </code>. This text is unwrapped (because of the code block). I want to write a javascript function that takes two arguments(starting...
0
by: Tom | last post by:
The included code block demonstrates programmatically clicking a non-derived ToolStripButton in the OnShown() method. When I derive a button from ToolStripButton and override the _private_...
0
by: taylorcarr | last post by:
A Canon printer is a smart device known for being advanced, efficient, and reliable. It is designed for home, office, and hybrid workspace use and can also be used for a variety of purposes. However,...
0
by: aa123db | last post by:
Variable and constants Use var or let for variables and const fror constants. Var foo ='bar'; Let foo ='bar';const baz ='bar'; Functions function $name$ ($parameters$) { } ...
0
by: ryjfgjl | last post by:
In our work, we often receive Excel tables with data in the same format. If we want to analyze these data, it can be difficult to analyze them because the data is spread across multiple Excel files...
0
by: emmanuelkatto | last post by:
Hi All, I am Emmanuel katto from Uganda. I want to ask what challenges you've faced while migrating a website to cloud. Please let me know. Thanks! Emmanuel
1
by: Sonnysonu | last post by:
This is the data of csv file 1 2 3 1 2 3 1 2 3 1 2 3 2 3 2 3 3 the lengths should be different i have to store the data by column-wise with in the specific length. suppose the i have to...
0
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However,...
0
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can...
0
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers,...
0
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.