Page 3 of 4 FirstFirst 1234 LastLast
Results 31 to 45 of 47
  1. #31
    Crash's Avatar
    Join Date
    Aug 2009
    Gender
    male
    Location
    JAville
    Posts
    2,881
    Reputation
    163
    Thanks
    3,291
    My Mood
    Sleepy
    Quote Originally Posted by tahha View Post
    hey dick can it

    the return 0; he was missing would crash if he had a longer program ive done it before and ended up losing the work.

    if you have

    Code:
    int main(){
    //lots of code here
    }
    then it can crash

    but
    Code:
    int main(){
    cout<<"Hey";
    }
    theres no need for it cus the program ends before theres a chance for it to lose the track of main

    as for
    Code:
    void main(){
    //code here
    }
    its not trying to return or look for the return of the value of main
    so it wouldnt have an issue at all
    if you would get your head out of the old ass books and learn the RIGHT way you would see this.
    Code:
    void printOut(char *noobName){
    
        cout<<"FUCK OFF " << noobName << " NOBODY CARES.";
    
    }
    
    int main(){
    
        printOut("tahha");
        return 1337;//<----------- notice that return
    
    }

  2. #32
    tahha's Avatar
    Join Date
    May 2010
    Gender
    male
    Location
    my keyboard or my bed
    Posts
    122
    Reputation
    9
    Thanks
    3
    Quote Originally Posted by Crash View Post
    Code:
    void printOut(char *noobName){
    
        cout<<"FUCK OFF " << noobName << " NOBODY CARES.";
    
    }
    
    int main(){
    
        printOut("tahha");
        return 1337;//<----------- notice that return
    
    }
    omg you can write out a loser code.... YOU ARE A GOD! PLEASE TEACH ME YOUR WAYS...dumb ass cunt

    stop trying to make others feel bad and teach someone something useful

    also i bet the OP would care if he could learn to code better for the future
    Last edited by tahha; 09-25-2010 at 03:15 PM.
    (BTW: My Name Is PowerHouse On Other Forums)

    Click this to get PowerHouse Private!

  3. #33
    DBag4Life69's Avatar
    Join Date
    Feb 2009
    Gender
    male
    Posts
    290
    Reputation
    13
    Thanks
    59
    My Mood
    Twisted
    Quote Originally Posted by tahha View Post
    omg you can write out a loser code.... YOU ARE A GOD! PLEASE TEACH ME YOUR WAYS...dumb ass cunt

    stop trying to make others feel bad and teach someone something useful

    also i bet the OP would care if he could learn to code better for the future
    I feel you on this, but I am sorry bro. I know Crash better, and he's my buddy. :P

  4. #34
    Crash's Avatar
    Join Date
    Aug 2009
    Gender
    male
    Location
    JAville
    Posts
    2,881
    Reputation
    163
    Thanks
    3,291
    My Mood
    Sleepy
    Quote Originally Posted by tahha View Post
    omg you can write out a loser code.... YOU ARE A GOD! PLEASE TEACH ME YOUR WAYS...dumb ass cunt

    stop trying to make others feel bad and teach someone something useful

    also i bet the OP would care if he could learn to code better for the future
    Loser code ?

    kk.

    You can if you want.


    teh omgz i r god kk i tech him somtin useful

    fstereeme is foar riting to teh files :

    Code:
    #include <fstream>
    
    using namespace std;
    ...
    
    fstream file("C://fag.txt", ios::out);
    
    file << "I r guna use teh return 0";
    
    file.close();
    
    return 0;
    
    ...
    Last edited by Crash; 09-25-2010 at 03:29 PM.

  5. #35
    DBag4Life69's Avatar
    Join Date
    Feb 2009
    Gender
    male
    Posts
    290
    Reputation
    13
    Thanks
    59
    My Mood
    Twisted
    Quote Originally Posted by Crash View Post
    Loser code ?

    kk.

    You can if you want.


    teh omgz i r god kk i tech him somtin useful

    fstereeme is foar riting to teh files :

    Code:
    #include <fstream>
    
    using namespace std;
    ...
    
    fstream file("C://fag.txt", ios::out);
    
    file << "I r guna use teh return 0";
    
    file.close();
    
    return 0;
    
    ...
    lolz. You're a dork. :P
    I already know how to write to a file.
    I am ON that section right now in my book. ;-)

    So, like this:
    [php]// Credits:
    // D-Vid aka Illusionz
    // flashlight95 -- For the idea of using the if
    // crash -- Freeing memory usage
    #include <iostream>

    int main()
    {
    using namespace std;
    float CppPrimer;
    int pages;

    cout << "Enter the total amount of pages that you've read so far: \n\n";
    cin >> pages;
    cout << endl;
    CppPrimer = 1225;
    if (pages>2501)
    {
    cout << "You input the incorrect value, it has to be less than 2501 pages." << endl;
    system("PAUSE");
    cout << endl;
    }
    else if (pages<2501)
    {
    cout << "Percentage outta the C++ Primer Plus: 5th Edition: " << pages / CppPrimer * 100 << "%" << endl;
    cout << "Percentage TOTAL outta all the books: " << pages / 2501 * 100 << "%" << endl;
    system("PAUSE");
    cout << endl;
    }
    else
    {
    cout << "You're DONE learning from those books!" << endl;
    system("PAUSE");
    cout << endl;
    }
    return 0;

    }[/php]


    What sucks is, by putting that if else statement in there, it gave me a problem:
    [IMG]https://i33.photobucke*****m/albums/d55/y_owns_you/problem.png[/IMG]

    EDIT:
    I fixed my problem, and it was YOUR fault, crash! Damnit. lolz.
    Here's the NEW code I fixed:
    Code:
    // Credits: 
    // D-Vid aka Illusionz
    // flashlight95 -- For the idea of using the if
    // crash -- Freeing memory usage
    #include <iostream>
    
    int main()
    {
    	using namespace std;
    	float CppPrimer = 1225;
    	float total = 2501;
    	int pages;
    
    	cout << "Enter the total amount of pages that you've read so far: \n\n";
    	cin >> pages;
    	cout << endl;
    	if (pages>total)
    	{
    		cout << "You input the incorrect value, it has to be less than 2501 pages." << endl;
    		system("PAUSE");
    		cout << endl;
    	}
    	else if (pages<total)
    	{
    		cout << "Percentage outta the C++ Primer Plus: 5th Edition: " << pages / CppPrimer * 100 << "%" << endl;
    		cout << "Percentage TOTAL outta all the books: " << pages / total * 100 << "%" << endl;
    		system("PAUSE");
    		cout << endl;
    	}
    	else
    	{
    		cout << "You're DONE learning from those books!" << endl;
    		system("PAUSE");
    		cout << endl;
    	}
    	return 0;
    
    }
    But now the NEW problem I am running into is that with that if statement, when I get done with the FIRST book, and say I have read all but one page. Total = 2501 last page = 2500
    I wanna make it where the line:
    Code:
    cout << "Percentage outta the C++ Primer Plus: 5th Edition: " << pages / CppPrimer * 100 << "%" << endl;
    doesn't come up with a value OVER 100%.
    How would I do that?
    Last edited by DBag4Life69; 09-25-2010 at 03:47 PM.

  6. #36
    tahha's Avatar
    Join Date
    May 2010
    Gender
    male
    Location
    my keyboard or my bed
    Posts
    122
    Reputation
    9
    Thanks
    3
    well fstream not just for writing to files
    its for file control as then reading and writing

    @OP i understand that you kno him and all but still he needs to learn not to be a jack ass if hes going to help someone
    i mean come on lets be a dick to someone trying to help the OP when you dont know what your on about
    i could understand if he was correcting me but only if it was in a nice way
    crash just thinks hes the shit be cus alot of people ask him for help.
    news for ya, YOUR NOT. when you are admin of a site then be a dick all you want
    when your just helping people and releasing more then others you may be liked but your not anything more then a more active member then most
    (BTW: My Name Is PowerHouse On Other Forums)

    Click this to get PowerHouse Private!

  7. #37
    Crash's Avatar
    Join Date
    Aug 2009
    Gender
    male
    Location
    JAville
    Posts
    2,881
    Reputation
    163
    Thanks
    3,291
    My Mood
    Sleepy
    Quote Originally Posted by tahha View Post
    well fstream not just for writing to files
    its for file control as then reading and writing

    @OP i understand that you kno him and all but still he needs to learn not to be a jack ass if hes going to help someone
    i mean come on lets be a dick to someone trying to help the OP when you dont know what your on about
    i could understand if he was correcting me but only if it was in a nice way
    crash just thinks hes the shit be cus alot of people ask him for help.
    news for ya, YOUR NOT. when you are admin of a site then be a dick all you want
    when your just helping people and releasing more then others you may be liked but your not anything more then a more active member then most
    Your rants do not affect /me.


    I don't think I'm "the shit". I know I'm nothing compared to others on this site.

  8. #38
    Mr.Magicman's Avatar
    Join Date
    Sep 2009
    Gender
    male
    Location
    Sitting in my cave full of thoughts learning Asembly
    Posts
    2,102
    Reputation
    16
    Thanks
    649
    My Mood
    Cold
    C++ things is C++ sections buisness... /yea

  9. #39
    Stephen's Avatar
    Join Date
    Jun 2009
    Gender
    male
    Location
    Engine.exe
    Posts
    4,689
    Reputation
    184
    Thanks
    1,149
    My Mood
    Aggressive
    Dont make me C++ spam again

  10. #40
    Insidious.'s Avatar
    Join Date
    Aug 2010
    Gender
    male
    Location
    General, -------- Critic Lvl: 10000000000000 [MPGH] Critic
    Posts
    1,285
    Reputation
    -174
    Thanks
    58

    Well good luckk,
    on learning C++.
    MPGH Critic
    "I Have 2 Red Bars, Beacuse i say the truth and the truth hurts you.!"
    -MJWL

    Use The Force
    [IMG]https://i44.photobucke*****m/albums/f34/Ps8612/Stars/gold.gif[/IMG][IMG]https://i44.photobucke*****m/albums/f34/Ps8612/Stars/gold.gif[/IMG][IMG]https://i44.photobucke*****m/albums/f34/Ps8612/Stars/gold.gif[/IMG][IMG]https://i44.photobucke*****m/albums/f34/Ps8612/Stars/gold.gif[/IMG][IMG]https://i44.photobucke*****m/albums/f34/Ps8612/Stars/gold.gif[/IMG]
    Contact Me Pm/Vm For Help!
    "It's Not Your House That's Haunted It's Your Son!"
    -Insidious

  11. #41
    DBag4Life69's Avatar
    Join Date
    Feb 2009
    Gender
    male
    Posts
    290
    Reputation
    13
    Thanks
    59
    My Mood
    Twisted
    Quote Originally Posted by Stephen View Post
    Dont make me C++ spam again
    lolz. I KNOW mofo.
    Don't start with that shit in MY thread. :P

    I am LEARNING C++
    C++
    C++
    C++
    C++
    C++
    C++
    C++
    C++
    mofo. lolz
    That's what I am doing here.

  12. #42
    deathninjak0's Avatar
    Join Date
    Feb 2009
    Gender
    male
    Posts
    1,510
    Reputation
    12
    Thanks
    294
    My Mood
    Cool
    Very nice man Goodjob

  13. #43
    richdude212's Avatar
    Join Date
    Jun 2009
    Gender
    male
    Location
    Tampa, FL
    Posts
    352
    Reputation
    10
    Thanks
    56
    My Mood
    Inspired
    Quote Originally Posted by whatup777 View Post
    Someone reading a book...Its the apocalypse!!!!!

    I lol'd. Thanks /
    [IMG]https://i516.photobucke*****m/albums/u330/richdude212-2.jpg[/IMG]


    [IMG]https://i516.photobucke*****m/albums/u330/richdude212/leet.gif[/IMG]

    Get NX Cash For Completing Offers Here! (will redirect)


    Remember to press when people help you!
    Not bad for $14.99 a month...

  14. #44
    freedompeace's Avatar
    Join Date
    Jul 2010
    Gender
    female
    Posts
    3,033
    Reputation
    340
    Thanks
    2,792
    My Mood
    Sad
    Don't "learn" it by reading off a book. Read the cplusplus.com tutorial up to pointers and stuff, and then go mess around with it !

    That's how I learnt C++, I didn't follow any tutorials at all :P

  15. #45
    DBag4Life69's Avatar
    Join Date
    Feb 2009
    Gender
    male
    Posts
    290
    Reputation
    13
    Thanks
    59
    My Mood
    Twisted
    Quote Originally Posted by freedompeace View Post
    Don't "learn" it by reading off a book. Read the cplusplus.com tutorial up to pointers and stuff, and then go mess around with it !

    That's how I learnt C++, I didn't follow any tutorials at all :P
    Welcome back, freedompeace. lolz
    I already read that whole tutorial, and it wasn't enough for me. I am a VERY knowledgeable individual, and I require MORE than just what a simple tutorial has to offer. I want to be GREAT.

Page 3 of 4 FirstFirst 1234 LastLast

Similar Threads

  1. Hey i want to learn to make with c++ code a pb proof wh please help
    By xaris in forum Call of Duty Modern Warfare Help
    Replies: 8
    Last Post: 05-05-2010, 10:57 AM
  2. CS 1.6 VAC2 proof hacks AND cheat death hacks
    By Brunogol in forum General Game Hacking
    Replies: 28
    Last Post: 12-18-2006, 08:26 PM
  3. Where could I learn C++? (Beginner, and Advanced stuff)
    By TsumikiriX in forum C++/C Programming
    Replies: 8
    Last Post: 07-19-2006, 08:11 PM
  4. Learn Hacking
    By Loler in forum Hack Requests
    Replies: 2
    Last Post: 01-22-2006, 03:20 PM
  5. Looking to learn.
    By SadisticGrin in forum Hack Requests
    Replies: 1
    Last Post: 01-15-2006, 06:57 PM