Reading some pieces of a file

From: ron (ronang_at_xs4all.nl)
Date: 12/30/04

  • Next message: B. v Ingen Schenau: "Re: Reading some pieces of a file"
    Date: Thu, 30 Dec 2004 08:38:14 +0100
    
    

    Is it possible that I make a textfile and open it with c++. But not all of
    the information has to be show.

    Example:
    Q = |How many people are there on the world?|
    A1 = |2.5 miljard|
    A2 = |3.0 miljard|
    A3 = |6.0 miljard|
    GA = A3

    Q = Question
    A* = Answer, with the multiple number
    GA = Good Answer

    I only want to show the senteces between the vertical rows
    The other information like 'Q, A1,A2,A3,GA' mustn't be show but I have to
    could read it.

    Then I could make an if/else statement like this:

    if GA {
    cout << "Good boy/girl!";
    } else {
    cout << "Not good!";

    Please help me!
    Very sorry for my bad English, I'm a Dutch guy of 14 years old, you
    understand :P


  • Next message: B. v Ingen Schenau: "Re: Reading some pieces of a file"