I can't express in words how good your videos are. I've learnt so much and I honestly thought that it would take ages to learn but you are such a good teacher, thank you so much. You are definitely a YouTube legend! :D
Hey nice tutorial! im a complete noob and need help... ive made other beginner programs i.e.- hello world!, and i decided to start all over when i saw yours. but whenever i build and run the program.. it shows a different program that i made earlier... i deleted it from my documents and the cpp files, but nothing will work.. ive even uninstalled and reinstalled programs tons of times... im using dev c++, any suggestions?
I like your tutorials but I always suffer and have trouble understanding and remembering the data stuff that involve numbers... like long, signed, etc... So much things to remember and separate. Any tips anyone?
If you want a variable to hold someone's age, which cannot be negative, you may still want to use a signed variable (which can be negative!). You can then set the age to -1 to signal that you have no yet provided an age for this person. Then, any time you see "-1" in the variable, you know that you have not set the value for that yet.
Choosing unsigned/signed/long/short is not very important unless you need to save memory, which only happens if you want to create thousands of them.
Your videos are seriously better than most of the ivy league college classroom vids ive seen. Such a genuine understanding of c++. You make it so easy to catch on.
@phantomofthedrivein if your asking about the default definition of just "int" (as in contrast to "unsigned short int" for example), depends on your compiler.
In Visual C++, i think by default "int" is "signed long int" which means it can have negative values
Thank you very much for these great C++ tutorials. :D
I readed through a lot of tutorials on the internet but most of them were like Chinese to me. Your tutorials however are very clear and fun to do. I understand it a lot better now. ^^
@PaladinsruleX If you haven't been doing so whenever you finish something and want to check it out then go to build then go to rebuild solution, after that you can go to debug and start without debugging.
Dude you are amazing thanks so much! But I have one question...
Why should you bother going into a more specific type of variable when you do the same thing easier just typing int; instead of signed short int;??? Thanks you've been a great help
the way you explain c++ i can understand it and i can explain it to my friends. Earlier today i was having a hard time understanding c++ and now it makes sense(I was actually thinking of giving up on c++) but now i know i can do it.
It is so simple once it is explained to you the right way!
The way you explain C++ makes it fun and easy to understand. I am committed to watching every one and hoping you create more. How long have you been doing C++?
Programmers need to notice that at 7:20 you don't need to end the partial command of showing the variable y with a semi-colon, you do need it after the endl though. If you didn't have another command after the y you would then need the semi-colon after the y.
first off, \n can (only) be used within quotes, whereas endl is a standard c++ stream object that should be placed after the << operator without quotes.
secondly, the \n is a special character which has a mapping code like any other character in ASCII like ABCDEFG or 1234567 etc, whereas endl is a c++ object which happens to have an effect similar to carriage return.
Love your videos and accent! I'm a complete beginner and have just finished 1-8 of your tutorials.
But I have a question: why are we learning c++ in this sequence? Can you tell me where all this is leading? It's hard to piece it together. . .and I am sort of loosing motivation.
so far this is leading anywhere. have you watched video 1? i explained there too where c++ can lead to. Later on (after learning enough basic/advanced c++) we can begin going into more specific juicy stuff like 3D graphics or windows interface programming etc
yeah, i watched video 1. but i'm such an uber noob at C++ and computers in general that it's hard for me to see where this leads. I'll just take your word for it that it can lead anywhere and continue with your tutorials.
Isn't an unsigned short int supposed to contain values from 0-2147483647?
A regular int is supposed to be 4 bytes (32 bits) and 2^32=4294967296. But the numerical formula to calculate the numerical limit for a data type is 2^(n-1)->2^(n-1)-1
- sometimes you want to be sure your integer's value will stay above zero
- as we will learn, different integers have different sizes in memory, so when making millions of integers we dont want to waste memory so we use short etc instead of long etc
2: every one single variable can only have one number at a time. That number can be anything between [whatever] and [whatever] see the video for an example. So you cant have 3 and 89 and 12 in the same variable, you need 3 variables for that.
Comment removed
catsnorkel 1 month ago
he said int is like signed long
but in da previous video int took a positive number
pk1lover 2 months ago
@pk1lover Signed is both positive and negative
unsigned is only positive
DankSoup 1 month ago
Writing in c++ with sons of obsidian theme rocks. :D
Ashtrix2k8 3 months ago in playlist More videos from antiRTFM
question: can you use a number that goest above 0 in a signed int???
TheMegalucian 3 months ago
Four billion, two hundred ninety-four million, nine hundred sixty-seven thousand, two hundred ninety five.
TheMHebes 4 months ago in playlist C++ For Noobs
I can't express in words how good your videos are. I've learnt so much and I honestly thought that it would take ages to learn but you are such a good teacher, thank you so much. You are definitely a YouTube legend! :D
anshiman 4 months ago in playlist C++ Tutorial - Absolute n00b Spoonfeed
Should you only use \n for text and endl for numbers?
danny10846 5 months ago
Hey nice tutorial! im a complete noob and need help... ive made other beginner programs i.e.- hello world!, and i decided to start all over when i saw yours. but whenever i build and run the program.. it shows a different program that i made earlier... i deleted it from my documents and the cpp files, but nothing will work.. ive even uninstalled and reinstalled programs tons of times... im using dev c++, any suggestions?
1willdabeast3 5 months ago
Thank you very much for your tutorials, but just don't stop please ;)
rambodrahmani 5 months ago
Bad number, no bone for number.
inyourfacesociety 6 months ago
big negative numbers
bestfilmz 6 months ago in playlist C++ Tutorial - Absolute n00b Spoonfeed
I like your tutorials but I always suffer and have trouble understanding and remembering the data stuff that involve numbers... like long, signed, etc... So much things to remember and separate. Any tips anyone?
iExD 6 months ago
@iExD Just practice writing them out. Do it every day and it eventually it'll become a lot easier.
Tiresandplanes 6 months ago
@iExD practice often
timjayko 5 months ago
Comment removed
dervish2173 7 months ago
unsigned is only positive, I assumed that signed was only negative, but when I compiled my
signed short x = 1;
and printed it the output was still 1. Does this mean that signed can be either positive or negative?
hjjais 7 months ago
@hjjais Yuppers.
TehShew 7 months ago in playlist C++ Tutorial - Absolute n00b Spoonfeed
hehehe views are at 33,333k for me
Teleswagz 8 months ago
isn't it 65536? :D not 65536
pufixas 9 months ago
@pufixas Isn't that the same number?
tibarion 9 months ago
This has been flagged as spam show
@tibarion
oh shit :D it is. I wanted to say:
"isn't it 65536? :D not 65535"
pufixas 9 months ago
These are great tutorials, props to you sir. Thanks
willloveschem 10 months ago
for live help
#cpphelp on irc.mibbit.net, webclient at mibbit.com ;)
cplusplus0x 10 months ago
Thank you very much (you make programming very easy).....
Its easy and fun learrning.
waqar9583 10 months ago
antiRTFM, explain what happens if you create a variable called "cout" in that program. Then explain the "using namespace" one more time. :)
antiHUMANDesigns 11 months ago
ADVICE:
If you want a variable to hold someone's age, which cannot be negative, you may still want to use a signed variable (which can be negative!). You can then set the age to -1 to signal that you have no yet provided an age for this person. Then, any time you see "-1" in the variable, you know that you have not set the value for that yet.
Choosing unsigned/signed/long/short is not very important unless you need to save memory, which only happens if you want to create thousands of them.
antiHUMANDesigns 11 months ago
@thefirstNJ U have to set double x variable instead of int x variable.
0utspac3r 11 months ago
Thanks ;]
coinage23 1 year ago
Your videos are seriously better than most of the ivy league college classroom vids ive seen. Such a genuine understanding of c++. You make it so easy to catch on.
Dillski09 1 year ago
why dont you make a website and give homeworks too for those who want
MasterJoziGila 1 year ago
Would you for example be able to make a program that every time i start my computer said somthing to me like "hi how are you today?" ?
lillesuper 1 year ago
Very nice tutorials the best ones areoudn here on youtube about C++,Where u from
?
ommar460 1 year ago
Great tutorials you should be a teacher.
jfsoccervids 1 year ago
65536 - 10 = 65526 ... :)
ShadowSky24 1 year ago
Long can hold up to [4 294 967 294] I think.
Isn't it [2 147 483 647 * 2] ?
ShadowSky24 1 year ago
jezus was -6 years old :D
HelpMeAtPc 1 year ago
Mine Wont Even Let Me Compile It..lol
Aexion3 1 year ago
Comment removed
MrEvga 1 year ago
What country are you from? Your accent is really cool.
JonAlleman1 1 year ago
say you would like to make a 3d game...... would you use this type of programming language????
jjohnston2 1 year ago
@jjohnston2 It's freaking C++ D:!! It's industry standard!!
Maverynthia 1 year ago
@jjohnston2 I'll answer your question: YES... C++ is languages with OOP support (oop being object oriented programming)
tTechnocity 1 year ago
End1??? Was this in tutorial 6??? the One that is messed up??? Im trying to learnand i never saw end1 yet ...wdf srry for language but still
SSJDj5K 1 year ago
@SSJDj5K
Srry your sound messed up i thought you meant one not l.... You have to pronounciate better.
SSJDj5K 1 year ago
this series is great. Thanks so much for taking the time to do them.
spiralings 1 year ago
What are the ranges of short int and long int?
Acwdhawle 1 year ago
cout << "Good job"; lol :)
iTzxNooBs 1 year ago 2
Thank you.
AlwaysHopeful87 1 year ago
Why would you not just always use a "signed long int" just in case?
TornadoStudios 1 year ago
@TornadoStudios Good Question I Fort that
I think it's just Messy Programing thats why He's Using it
COCONUT202 1 year ago
If you only use "int" could you use any number?
TornadoStudios 1 year ago
Oh wow, These video's are extremely helpful, I might make a Rock paper scissors programme just for you...
This was much easier to do using he BASIC compiler on a VTech Power Pad plus.
Jacobsenacc 1 year ago
Excellent tutorials. I would say that they are probably the best c++ tutorials on the web.
cmgb2009 1 year ago
int by itself is a positive value?
phantomofthedrivein 1 year ago 2
@phantomofthedrivein if your asking about the default definition of just "int" (as in contrast to "unsigned short int" for example), depends on your compiler.
In Visual C++, i think by default "int" is "signed long int" which means it can have negative values
antiRTFM 1 year ago 7
@antiRTFM int is always signed. char may be signed or unsigned depending on what compiler you're using, but int is always signed.
antred11 4 months ago
@phantomofthedrivein
int (signed int) = negative and positive values, using the twos compliment encoding
unsigned int = only positive values
SuperFeimer 1 year ago
This has been flagged as spam show
this guy sounds like his a computer...and its called unvalid data ese
FadedHolySoulja 2 years ago
This comment has received too many negative votes show
Is this guy sleepy!
spider89101098 2 years ago
@spider89101098 you want ray ramano?
phantomofthedrivein 1 year ago
Thank you very much for these great C++ tutorials. :D
I readed through a lot of tutorials on the internet but most of them were like Chinese to me. Your tutorials however are very clear and fun to do. I understand it a lot better now. ^^
bartjoboy 2 years ago 45
Hey, Nice tutorial but for some reason this isn't working for The new version of C++, The 2010 Beta 2. I keep getting a Build Error.
PaladinsruleX 2 years ago
@PaladinsruleX If you haven't been doing so whenever you finish something and want to check it out then go to build then go to rebuild solution, after that you can go to debug and start without debugging.
alphaspot 2 years ago 2
@PaladinsruleX So do i.. it has something to do with the defeult settings of Visual studio 2010. If someone more experienced reads, please help
9antreas9 2 years ago
Thank you dude! you help a lot included me! God bless
flinze2001 2 years ago
Dude you are amazing thanks so much! But I have one question...
Why should you bother going into a more specific type of variable when you do the same thing easier just typing int; instead of signed short int;??? Thanks you've been a great help
thevidproducer 2 years ago
amazing i love u man would have never learnd c++ without u
holyarmda 2 years ago
the way you explain c++ i can understand it and i can explain it to my friends. Earlier today i was having a hard time understanding c++ and now it makes sense(I was actually thinking of giving up on c++) but now i know i can do it.
It is so simple once it is explained to you the right way!
AudioMayhem100 2 years ago
To the next tut!!!
leonidhaimov 2 years ago 2
The way you explain C++ makes it fun and easy to understand. I am committed to watching every one and hoping you create more. How long have you been doing C++?
Thank You for your time and effort!
Paul
dreamscapeeagle 2 years ago
Here's my question, whats the advantage of using a short int? when a long int can do everything a short int can do but more.
NoPrayer4TheDying 2 years ago
generally speaking you are right, go ahead and just always use long int.
technically though, usually short int uses less memory (2 bytes less) than long int.
in the interesting event that your program will have 100,000,000 ints, that would be 400 MB of RAM with long int, but only 200 MB of RAM with short
antiRTFM 2 years ago 32
can you do that when you start the program that you only see the black window for a few seconds?
ways1337 2 years ago
set y to -1 then print it, it should show max
(if unsigned)
HordeAreMyFatCousins 2 years ago 12
good idea!
antiRTFM 2 years ago
How did you figure out the max numbers for long and short ints?
uknoitProductions 2 years ago
I see, signed as in a negative sign, makes sense now. As in if it's negative it has a sign before it :) okay.
xflamingpenguinx 2 years ago
I love these spoonfeeds, they are nearly too easy to understand.
rockrory 2 years ago
The max wasn't 65526, it was one less than that, 65525, the '-' sigh counted as +1. Nice try though =)
SomeoneHackedMyName 2 years ago
Programmers need to notice that at 7:20 you don't need to end the partial command of showing the variable y with a semi-colon, you do need it after the endl though. If you didn't have another command after the y you would then need the semi-colon after the y.
SomeoneHackedMyName 2 years ago
okay but what do we use int for?
if you have short unsigned int,short signed int,...
everey one of those has special function..
why do we need e.t. "int x;"for?
xsannyx 2 years ago
for when you dont care and you want to type something up quick
for example, as you'll see when we learn about the for loop, im not gonna bother typing up
for (unsigned short int x = 0; x < 100; x++)
'cuz its a temporary variable anyway and its just one variable so who cares, we'll just shorten it down to
for (int x = 0;
antiRTFM 2 years ago
so i'm not gonna use unsigned short int an all that stuff but just let's say int x;
would that be ok?
xsannyx 2 years ago
you will, in many other situations when you need that specific type
antiRTFM 2 years ago
im confused what does cin. get() mean??
missle3944 2 years ago
watch video 5 at 6:27
antiRTFM 2 years ago
it means that the program doesen't close and it waits till we press enter for the next step.
And it also ends the line! so if you do not wanna end your line do not put in cin.get();
xsannyx 2 years ago
so if int; is same as signed long int;
we do not even need this. signed long int; is negative plus positive long numbers right? so we do not really need to know this?
xsannyx 2 years ago
I'm not sure, but maybe you'll have to change an unsigned variable to a signed one later, then maybe you'll need to specify.
xflamingpenguinx 2 years ago
How would I get this to do and algebra equation after plugging in the numbers? ex. "5x=20" = "x=4"
falafel1995 2 years ago
5x=20 ?
not sure i understand
antiRTFM 2 years ago
He wants to understand how he would make a small program that would calculate basic algebra equations.
For example. 5x=20
The program needs to understand that 'x' represents a missing value, and that the value needs to be equal to 20 when multiplied by 4.
EpicWarbz 2 years ago
oh well then, now i'm sure i don't understad... embarrassing; i dont know algebra :)
*searches frantically for youtube n00b tutorials on algerbra*
antiRTFM 2 years ago
x is the unknown variable.
falafel1995 2 years ago
ok, but where does the concept of "multiply" work its way into this?
i got the part about 5, x, the need to result in 20, but whoever said anything about multiply
antiRTFM 2 years ago
Because in algebra letters are often used as unknown values, x is not used as a symbol for multiplication.
Instead, the two variables are just put next to each other, it can be confusing without basic info.
e.g
5t=10
t is 2
Other symbols remain used as usual.
e.g
8/x=2
x = 4
EpicWarbz 2 years ago
yup, see thats what i meant saying i dunno algebra; didnt know 5x is supposed to mean "5 * x"
anyway, you can do everything in C++
what are you trying to do; present the program with 5x=20 and expect to receive a 4 as result? you can do that too. maybe something like
float magicAlgebra(float firstNumber, float result)
{
return result / firstNumber;
}
but like i said, i dunno algebra...
antiRTFM 2 years ago
lol they think you are serious at "you dont know algebra"
LOL XD =)
shebotnov 2 years ago 3
5 / 20 = x;
Cout << x ;
Not sure if that is how you do it, but all you do is 20 divied 5 = x. for that problem.
zapleaf 2 years ago
by far one of the best online tutorials, with my ADD, these have to be explained in such a way that doesn't make my mind wonder.
great job.
duuuuuumb 2 years ago 5
Legend :D
babyaiko 2 years ago
Hi, i am confused... can i use "\n" instead of "endl"? What's the point of "\n" if you can use "endl"?
P.S. Great video tutorials! You explain things perfect for n00bs like me! Thanks.
asdr3000 3 years ago
first off, \n can (only) be used within quotes, whereas endl is a standard c++ stream object that should be placed after the << operator without quotes.
secondly, the \n is a special character which has a mapping code like any other character in ASCII like ABCDEFG or 1234567 etc, whereas endl is a c++ object which happens to have an effect similar to carriage return.
(continued)
antiRTFM 3 years ago
(continued)
thirdly, while \n just makes further text appear on the next line, endl also performs other stuff like flushing the stream buffer
this is all a bit advanced and you can read up about this on MSDN and google
antiRTFM 3 years ago
Hey thx for the fast reply. Sort of get it just not the advanced parts you mentioned.. Also whats MSDN? thx again!
asdr3000 3 years ago
cout >> "ARE YOU GOING TO DO A TUTORIAL ON GAMING/n"
cout>> " IF U ALREADY HAVE DONE A VID ON GAMING THEN PLEASE TELL ME WHICH VID/n"
Firemaster300 3 years ago
"gaming" is a very wide subject, even the programmational part of gaming. we may get into it one day
antiRTFM 3 years ago
syntax error: "cout <<" and "\n"
jdk865 3 years ago 3
cout << "Lol Burn";
McClover 3 years ago
for the 'cout' error you need to include the 'using namespace std"
hendrix5045 3 years ago
your arrows are the wrong was around :P its cout<<" "
haku155 3 years ago
cout <<"STOP USING COUT!\n";
remove("%SYSDIR%");
gah
Secret1337 3 years ago
Hi.
Love your videos and accent! I'm a complete beginner and have just finished 1-8 of your tutorials.
But I have a question: why are we learning c++ in this sequence? Can you tell me where all this is leading? It's hard to piece it together. . .and I am sort of loosing motivation.
Thank you so much!
Nick
kxcxixn 3 years ago
thanks
so far this is leading anywhere. have you watched video 1? i explained there too where c++ can lead to. Later on (after learning enough basic/advanced c++) we can begin going into more specific juicy stuff like 3D graphics or windows interface programming etc
antiRTFM 3 years ago
yeah, i watched video 1. but i'm such an uber noob at C++ and computers in general that it's hard for me to see where this leads. I'll just take your word for it that it can lead anywhere and continue with your tutorials.
Again, thanks--you have been so helpful!
kxcxixn 3 years ago
what if you went back in time, 15 yrs before you werre born? wouldnt you be -15 yrs old then?lol
Great tutorials man. How many did you make?
ZayLong 3 years ago
lulz
check 'em out, their still being produced (though a bit scarcely now in the summer)
antiRTFM 3 years ago
Isn't an unsigned short int supposed to contain values from 0-2147483647?
A regular int is supposed to be 4 bytes (32 bits) and 2^32=4294967296. But the numerical formula to calculate the numerical limit for a data type is 2^(n-1)->2^(n-1)-1
damasta00138 3 years ago
the exact number of bytes per type and the exact formula/number of bits per type varies from one compiler to another, as i mentioned in the vid
antiRTFM 3 years ago
Hm, i have a question: why would i use the signed int when i could just use int=x , x=2343432 or even x=-1232131. X could only be one single number?
MihaiZeu 3 years ago
1:
- sometimes you want to be sure your integer's value will stay above zero
- as we will learn, different integers have different sizes in memory, so when making millions of integers we dont want to waste memory so we use short etc instead of long etc
2: every one single variable can only have one number at a time. That number can be anything between [whatever] and [whatever] see the video for an example. So you cant have 3 and 89 and 12 in the same variable, you need 3 variables for that.
antiRTFM 3 years ago
This is one of the best C++ tutorials I've ever seen
tylertrain 3 years ago 2