Jump to content
  • Advertisement

DeathsBargin

Member
  • Content Count

    53
  • Joined

  • Last visited

Community Reputation

128 Neutral

About DeathsBargin

  • Rank
    Member
  1. DeathsBargin

    Why isn't this working the way I wan't it to?(C++)

    Quote:Original post by davidjustus since he gave up, here is the above code, fixed and simplified, with a per line explanation.. *** Source Snippet Removed *** I did not give up.... i just tried to make a program obviously too far ahead in the book i am reading. So I have decided to wait untill I am far enough into the book and understand what I am being told.
  2. DeathsBargin

    [web] easy html question...

    Quote:Original post by M2tM *** Source Snippet Removed *** check out webmonkey And beware of asking silly and stupid questions like this. This is another one of those things you could very easily google. I'm not answering any more of your questions until you put some effort into answering them yourself. Don't go through life being spoon fed or you'll be mistaken for a vegtable and eventually will become one. I have searched through yahoo search for 25 minutes with no results I desire. I do put effort into what I am asking... I had notes on this before but they were lost when I cleaned my comp out. ____ Also, if this is the way you will react while answering my questions, I really don't mind that you don't answer them.
  3. how do I make a picture link to another webpage? (im using it for navigation)
  4. DeathsBargin

    Why isn't this working the way I wan't it to?(C++)

    you can't see that very well... Im just going to give up on this for the time being... its obviously something I have yet to learn and I will get in the future. Thanks for everyones help really, though you think you have done nothing you have really helped.
  5. DeathsBargin

    Why isn't this working the way I wan't it to?(C++)

    Im sorry I had to ask.... but why am i getting this now?(im still trying to understand what you said so i messed around with it and got #include <cstdlib> #include <iostream> using namespace std; int main(int argc, char *argv[]) { char count; count = 1; cout<<"Please press ENTER to begin counting."<<endl; cin.get(count); while (count <= 25) { cout<<"PRESS ENTER" <<endl; cout<< count <<endl; cin.get(count); count ++; } system("PAUSE"); return EXIT_SUCCESS; }
  6. DeathsBargin

    Why isn't this working the way I wan't it to?(C++)

    Quote:Original post by M2tM *smacks his forehead* Dude. *** Source Snippet Removed *** It's cool that you're new, but learn to learn. This is a question good ol' google could answer easily. cin.get() is different from cin.get(someChar) which expects a character. You need to read a beginners book. There are several good ones, just look around your local bookstore. First of all didn't see the code their at all b4. Secondly I appreciate the help you guys are giving me, even though you may think I don't. Thirdly I got a book right here in my lap...(C++ Without Fear by Brian Overland) and I have read into the cin sections and nowhere does it talk about cin.get() in any forum(yes i checked the index aswell)
  7. DeathsBargin

    Why isn't this working the way I wan't it to?(C++)

    cin.get() //gets the whole line cin.get(variable)//gets specified variable.. this is what I found
  8. DeathsBargin

    Why isn't this working the way I wan't it to?(C++)

    Quote:Original post by M2tM I tested this with success, it should work for you: #include <iostream> int main(){ std::cin.get(); return 0; } this is my code and it will not work(I don't have std::cin.get() cause i said using at the top #include <cstdlib> #include <iostream> using namespace std; int main(int argc, char *argv[]) { char count; count = 1; cout<<"Please press ENTER to begin counting."<<endl; cin>>count; while (count <= 25) { cout<<"PRESS ENTER" <<endl; cout<< count <<endl; cin.get(count); return 0; count ++; } system("PAUSE"); return EXIT_SUCCESS; } __________ Edit: I may see my problem _____ reedit: was wrong... heres new code again.. #include <cstdlib> #include <iostream> using namespace std; int main(int argc, char *argv[]) { char count; count = 1; cout<<"Please press ENTER to begin counting."<<endl; cin.get(count); while (count <= 25) { cout<<"PRESS ENTER" <<endl; cout<< count <<endl; cin.get(count); return 0; count ++; } system("PAUSE"); return EXIT_SUCCESS; }
  9. DeathsBargin

    Why isn't this working the way I wan't it to?(C++)

    Quote:Original post by M2tM std::cin.get(); may work, though I think you need to actually enter a character there as well... if you have access to conio.h with your compiler you can use while(!kbhit()){;} yea i tried, you still need a char... and i have no clue what the other things are, so I don't really want to use them.
  10. DeathsBargin

    Why isn't this working the way I wan't it to?(C++)

    Quote:Original post by Bregma Quote:Original post by DeathsBargin I want it to show you count and then ask you to press enter, after you press enter count should go up by one, display this, and then display, repeat the process till we get to 25. (a) what happens when you type "24[return]" at the prompt? (b) what happend when you type "0[return]" at the prompt? (c) what happens when you type "x[return]" at the prompt? If i have it set on char then x is the only one that will work and it will just terminate if i use something else(except for space which is just going down a blank line) if i have it for int it dosent matter what number i use it still goes up a number
  11. DeathsBargin

    Why isn't this working the way I wan't it to?(C++)

    Quote:Original post by M2tM a char... space dosen't count as a char
  12. DeathsBargin

    Why isn't this working the way I wan't it to?(C++)

    Quote:Original post by ChaosX2 The first problem is when your using cin on count you are overwritting the value of count. define: char somevar; cin >> somevar; instead. I didn't find any problems other than i need to press and int instead of space..(And obviously thats not what I want)
  13. DeathsBargin

    Why isn't this working the way I wan't it to?(C++)

    ah, i just tested that your right....*Smacks self in face..* int = integer duh! So what would I store it in if I wanted it to do a space?
  14. #include <cstdlib> #include <iostream> using namespace std; int main(int argc, char *argv[]) { int count; count = 1; cout<<"Please press ENTER to begin counting."<<endl; cin>>count; while (count <= 25) { cout<<"PRESS ENTER" <<endl; cout<< count <<endl; cin>>count; count ++; } system("PAUSE"); return EXIT_SUCCESS; } I want it to show you count and then ask you to press enter, after you press enter count should go up by one, display this, and then display, repeat the process till we get to 25. But it won't display anything...
  15. DeathsBargin

    What has annoyed you the most this year? (long post!)

    ok, "hypathtically speaking" lets just SAY there was a president whom sucked at his job. Well, I don't know one but If anyone eles does I wouldnt mind hearing which one it is.....(Certainly not the good 'ol guy Bush though :P)
  • Advertisement
×

Important Information

By using GameDev.net, you agree to our community Guidelines, Terms of Use, and Privacy Policy.

GameDev.net is your game development community. Create an account for your GameDev Portfolio and participate in the largest developer community in the games industry.

Sign me up!