Results 1 to 5 of 5

Thread: c++ help (strings)

  1. #1

    Question c++ help (strings)

    can anybody make from this line an variabel (a string) (long or char variable or both)

    std::cout << "\n0x" << std::string << newCrc << std::endl;

    please help..

    whole code here
    Bill has the key to the \'blue\' screen
    by tux

  2. #2
    Senior Member
    Join Date
    Oct 2001
    I'm not sure exactly what you are asking. Do you want "\nox" to be in a string called newCrc?
    if so something like this would be fine:

    using std::cout;
    using std::cin;
    using std::string;

    int main(){

    string newCrc;
    cout << "Enter sting: ";
    cin >> newCrc;

    cout << newCrc << '\n';
    return 0;

    Hope that helps.
    Ben Franklin said it best. \"They that can give up essential liberty to obtain a little temporary safety deserve neither liberty nor safety.\"

  3. #3
    The Lizard King SarinMage's Avatar
    Join Date
    Jan 2002
    New York
    i would help you but i dont quite understand what your asking... explain it a little bit more

  4. #4
    Junior Member
    Join Date
    Apr 2003
    ok, here's what you do...

    think b4 about what you're trying to say.. put them in words that makes sense .. then present them in text..
    Tha all mity Rodent!

  5. #5
    I have already the answer

    Bill has the key to the \'blue\' screen
    by tux

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts