c++ - How do I correct "expected primary-expression before...?" -


i'm beginning program , have no idea i'm doing. professor gave program sets , i've completed it, when compile file

" j:\untitled1.cpp in function `int main()':

"36 j:\untitled1.cpp expected primary-expression before '<<' token "

here's full set, remember i'm beginner:

/** concepts program #1, template program name: yay.cpp program/assignment:  description: finds total input(s):  output(s):  suffering_with_c++ date of completion  */ //included libraries #include <iostream> #include <iomanip> #include <stdlib.h> #include <time.h.>  #define cls system("cls") #define pauseoutput system("pause")//  using namespace std; int main()  {     //variable declaration/initialization     time_t nowisthemoment;     time(&nowisthemoment);      string datetime;//      cls;     cout <<"\new live in moment--only moment ours. current date , time is: "     <<ctime (&nowisthemoment); << endl;//     cout << "\nmy name moe joe." <<endl;//     cout << endl << "i think computer programming c++ bit more phun now!"           << endl;     datetime = ctime(&nowisthemoment);//     cout << endl << "\nyo ho! here now...\n" << endl;     cout << endl << "the current date , time is: "      <<datetime <<endl;//     cout << "\ni know that, if not comment programs/project work thorougly, lose substantial points.\n" ;      cout << "\bhere pause output in action....\n" << endl;//     pauseoutput; //     cls;//     return 0;  } 

remove semicolon on line 36

<<ctime (&nowisthemoment); << endl;                          ^                          | 

Comments

Popular posts from this blog

html - How to style widget with post count different than without post count -

How to remove text and logo OR add Overflow on Android ActionBar using AppCompat on API 8? -

javascript - storing input from prompt in array and displaying the array -