Continue to Site

Welcome to EDAboard.com

Welcome to our site! EDAboard.com is an international Electronics Discussion Forum focused on EDA software, circuits, schematics, books, theory, papers, asic, pld, 8051, DSP, Network, RF, Analog Design, PCB, Service Manuals... and a whole lot more! To participate you need to register. Registration is free. Click here to register now.

Question about C++ syntax

Status
Not open for further replies.

fatma1000

Banned
Joined
Apr 30, 2006
Messages
147
Helped
3
Reputation
6
Reaction score
2
Trophy points
1,298
Location
eygpt
Activity points
0
is it posseble to do like this
main()
int x;
float y;
{
----------------
--------------
-----------------
}
regards
 

help6 c++

No. Isn't possible
 

help6 c++

Nope sorry. Not gonna work.
Why you wanna do that?
 

Re: help6 c++

main()
{
int a;
float b;
--------------
----------------
------------

}
 

Re: help6 c++

why would you even want to do anything like that???
what you can do is
Code:
int main() 
{
int a;
float b;
// ---------------
//------------
//----------------

}
it really doesn't do anything useful though.
 

help6 c++

this is better:
int main ( void ) // void - because we don't parse argument string of program
{
int a;
float b;
// ---------------
//------------
//----------------
return 0; // because we write int main, so it must return some value to OS
}
 

Status
Not open for further replies.

Part and Inventory Search

Welcome to EDABoard.com

Sponsor

Back
Top