cplusplus
.com
TUTORIALS
REFERENCE
ARTICLES
FORUM
C++
Tutorials
Reference
Articles
Forum
Forum
Beginners
Windows Programming
UNIX/Linux Programming
General C++ Programming
Lounge
Jobs
Forum
Beginners
Do I always need to put "int" when decla
Do I always need to put "int" when declaring a variable?
Sep 4, 2013 at 8:31am UTC
Noct
(5)
In c++ is it always needed to use int when declaring a variable? unlike python you just type any character and your good.
Sep 4, 2013 at 8:39am UTC
vlad from moscow
(6539)
Yes if the variable has to have the type int. Also you can substitute type specifier int for type specifier signed or use the both in the declaration,
In C++ the compiler checks types of variables at compilation time.
Last edited on
Sep 4, 2013 at 8:55am UTC
Sep 4, 2013 at 8:49am UTC
m4ster r0shi
(2201)
However, there's a very interesting project lying around, which attempts to add
dynamic typing cababilities to C++ ->
https://code.google.com/p/dynamic-cpp/
Topic archived. No new replies allowed.