C++ help

Discussion in 'Programming General' started by ryanboyd, Oct 24, 2018.

C++ help
  1. Unread #1 - Oct 24, 2018 at 9:08 AM
  2. ryanboyd
    Joined:
    May 28, 2016
    Posts:
    461
    Referrals:
    0
    Sythe Gold:
    13
    Discord Unique ID:
    203906109067493377
    Rust Player Dragon Claws Easter 2017 Extreme Homosex Potamus

    ryanboyd Forum Addict
    $25 USD Donor New

    C++ help

    hello everyone im learning cpp at the moment and im trying to figure something out

    So this is my code
    Code:
    
    class ryan { 
    public:
    
    cout << "hello world" << endl;
    
    };
    
    
    int main(){
    
    cout << ryan ;
    
    return 0;
    }
    
    
    how do i cout that line im kinda confused
     
    ^ Fyrix likes this.
  3. Unread #2 - Oct 24, 2018 at 9:28 AM
  4. ryanboyd
    Joined:
    May 28, 2016
    Posts:
    461
    Referrals:
    0
    Sythe Gold:
    13
    Discord Unique ID:
    203906109067493377
    Rust Player Dragon Claws Easter 2017 Extreme Homosex Potamus

    ryanboyd Forum Addict
    $25 USD Donor New

    C++ help

    anyone reading this i figured it out
    Code:
    class Sentence {
      public:
       
      string message1 = "Welcome to the shop! Choose from the options below!";
       
    };
    
    int main() {
    bool shop = true;
    bool firstmessage = true;
    
    
    while(shop == true){
      if(firstmessage == true){
      Sentence storenew;
      storenew.message1;
      cout << storenew.message1;
      };
    
     
    ^ Fyrix likes this.
  5. Unread #3 - Oct 25, 2018 at 3:55 PM
  6. RSGilded
    Joined:
    Apr 13, 2018
    Posts:
    912
    Referrals:
    1
    Sythe Gold:
    2,253
    Discord Unique ID:
    238479136174112768
    Discord Username:
    RSGilded#5921
    Pokémon Trainer Lawrence Potamus Heidy <3 n4n0 Extreme Homosex Supporting Business Two Factor Authentication User

    RSGilded Buy Runescape Gold | RSGilded.com
    $500 USD Donor

    C++ help

    Why do you have a while loop in there. Completely unnecessary in my opinion.
     
    ^ Fyrix likes this.
  7. Unread #4 - Oct 26, 2018 at 6:00 AM
  8. ryanboyd
    Joined:
    May 28, 2016
    Posts:
    461
    Referrals:
    0
    Sythe Gold:
    13
    Discord Unique ID:
    203906109067493377
    Rust Player Dragon Claws Easter 2017 Extreme Homosex Potamus

    ryanboyd Forum Addict
    $25 USD Donor New

    C++ help

    this isnt the entire code sorry would you like to see the entire code that i have so far its super messy im going to clean it up when i have the code working 100%
     
    ^ Fyrix likes this.
  9. Unread #5 - Oct 26, 2018 at 10:16 AM
  10. RSGilded
    Joined:
    Apr 13, 2018
    Posts:
    912
    Referrals:
    1
    Sythe Gold:
    2,253
    Discord Unique ID:
    238479136174112768
    Discord Username:
    RSGilded#5921
    Pokémon Trainer Lawrence Potamus Heidy <3 n4n0 Extreme Homosex Supporting Business Two Factor Authentication User

    RSGilded Buy Runescape Gold | RSGilded.com
    $500 USD Donor

    C++ help

    No worries dude, If you need any help with c++ lmk cause im pretty decent at it.
     
    ^ Fyrix likes this.
< C++ Error | Requesting guidance to making simple scripts with C# >

Users viewing this thread
1 guest


 
 
Adblock breaks this site