Search:

Type: Posts; User: falzone

Search: Search took 0.01 seconds.

  1. Replies
    4
    Views
    1,182

    i tried the codes but it cant work? any...

    i tried the codes but it cant work? any suggestion what the error might be due to?



    string str = "this is a string";
    string tmp;
    while(str >> tmp)
    cout << tmp;
  2. Replies
    7
    Views
    12,623

    Hi this is my code that got error when encounter...

    Hi this is my code that got error when encounter blank lines.



    while(!textFile.eof())
    {
    if(line == 0)
    { ...
  3. Replies
    7
    Views
    12,623

    Ignoring line in C++ when reading from file

    Hi all!

    I have the following codes i use to read from a textfile.



    while(!textfile.eof())
    { //textfile is a ifstream
    textfile >> string1 >> string2;
    ...
  4. Replies
    3
    Views
    979

    thanks both of u! the solution works wonders :)

    thanks both of u! the solution works wonders :)
  5. Replies
    3
    Views
    979

    calculate numbers

    Hi,

    How can i calculate numbers and round off the decimal point to 2 decimal places?

    for example i have 2 numbers 5 and 3

    the result of 5 divide by 3 is 1.666666666

    i want it to return...
  6. Replies
    4
    Views
    1,182

    delimiting string

    Hi,

    I have a string array. In this string array for example if i get teststring[0] out it returns me "this is a test string".

    with this string its delimited by white spaces. But i am having...
Results 1 to 6 of 6