Begginers assignment

thank you
Last edited on
What specifically are you having trouble with?
I keep getting the errors:

In function 'int main()':
28 8 [Error] expected unqualified-id before 'char'

37 14 [Error] 'name' was not declared in this scope
40 17 [Error] 'date' was not declared in this scope
Line 27: you used a comma instead of a semicolon
still shows the same errors. :(
Show me lines 22 to 30 as you have them now
thank you
Last edited on
Yes, the compiler has no problem with the earlier code so now it can take a look at the later code.

http://ideone.com/9YIlvq
prog.cpp: In function ‘int main()’:
prog.cpp:37:40: error: no match for ‘operator<<’ (operand types are ‘std::basic_istream<char>::__istream_type {aka std::basic_istream<char>}’ and ‘<unresolved overloaded function type>’)
  cin.getline(name, (sizeof(name) - 1)) << endl;
                                        ^
Why is that << endl there??
thank you] 'system' cannot be used as a function
Last edited on
What compiler are you using? The code runs fine:

http://ideone.com/2lRALT
How can I tell which compiler I am using? I have the Dev c++. And i just press F10 which compiles it and runs it/.
Dev-C++ is outdated and deprecated:
http://www.cplusplus.com/articles/36vU7k9E/
~~~~~~~~~~~~~~~~~~~~~~~~~

Customer Nameexample

Order Date one

Reprint Cost 0.50
Tax Amount 18795070
Total Cost 18795070


Press any key to continue . . .

thats what came out, it looks like the calculation didn't come out accurate. When it ask for the customers name, i type example and click enter, and it just goes to the second line .
Then it asks me for the order date and i put the date and the number of photos, but none of the calculations come out correct.
Topic archived. No new replies allowed.