• YOU can help the next generation of students in the community!
    Share your trial papers and notes on our Notes & Resources page

Has anyone started on COMP115 Assigment 1? I need help! (1 Viewer)

TheDreamer

New Member
Joined
Mar 10, 2004
Messages
20
Has anyone started on the assignment 1?

I haven't yet but will soon. It's just I keep get getting errors on the examples and I don't know how to rectify them.

For eg. Would anyone know what 'parse error' means?
 

jlh

sooner or later...
Joined
Mar 15, 2003
Messages
1,755
Location
Sydney
Gender
Male
HSC
2002
yes i've started and finishes.. well kinda finished, i have to remedy a bug in mine...
 

TheDreamer

New Member
Joined
Mar 10, 2004
Messages
20
Already!! argh. I haven't a clue to do. But I have a feeling it's to do with If Statements?

By the way, since we can't discuss Assignment question, have you done the Prac week 2 exercise? I've started it since I have my prac tomorrow but I constantly keep getting a 'parse error'. Do you know what that means?
 

-=«MÄLÅÇhïtÊ»=-

Gender: MALE!!!
Joined
Jul 25, 2002
Messages
1,678
Location
On Top
Gender
Male
HSC
2002
parse error from memory occurs when u type in sumfin that doesnt make sense. like a typo
u prolly left out a ;
 

jlh

sooner or later...
Joined
Mar 15, 2003
Messages
1,755
Location
Sydney
Gender
Male
HSC
2002
An error encountered during parsing of an input stream due to invalid syntax.
 

jlh

sooner or later...
Joined
Mar 15, 2003
Messages
1,755
Location
Sydney
Gender
Male
HSC
2002
yes i've done prac2 tasks... they are actually pretty easy..
 

TheDreamer

New Member
Joined
Mar 10, 2004
Messages
20
To be exact, it says , 'parse error before <' '? in response to this:
cout << "x + y ==" ;
Don't think there was a missing ; or typo.

I'm really bad at this stuff, by the way. lol
 

jlh

sooner or later...
Joined
Mar 15, 2003
Messages
1,755
Location
Sydney
Gender
Male
HSC
2002
what exactly are you trying to do??
i take it you are doing task 3? basicop.cpp?

do you have msn it would be easier to chat to you there...

i'm assuming that you'v declared x and y? if you have get rid of the " " marks..

you don't need to "quote" functions/variables...
 

-=«MÄLÅÇhïtÊ»=-

Gender: MALE!!!
Joined
Jul 25, 2002
Messages
1,678
Location
On Top
Gender
Male
HSC
2002
check out the line above it..
if u left out ; in line b4, it goes to the next line

post ur entire source code...
or juz ask jlh privately..he seems to know wat he's doing..i used to be good..but now ive 4gotten everything

edit: are u making a calculator?

remember that == is for instruction purposes in c++, so its only useful if u have it in an if statement, but wen ur gonna cout it than theres no need to do so.

so ur line should perhaps look more like

cout << " x + y = " << x+y << endl;
 
Last edited:

sukiyaki

emptiness
Joined
Nov 9, 2002
Messages
1,505
Location
westie
Gender
Female
HSC
2003
did msot of you guys did software in year 12?
i dont understand the assignment at all ...
 

bong

Member
Joined
Jun 11, 2003
Messages
433
Gender
Male
HSC
2003
basically, u'll need to read ahead, doche hasnt taught enough to let u do the assignment without prior programming knowledge.
 

jlh

sooner or later...
Joined
Mar 15, 2003
Messages
1,755
Location
Sydney
Gender
Male
HSC
2002
no i didn't do software in year 12!!

he can't post the stuff on the net because its the weekly assignment!! LOL
 

-=«MÄLÅÇhïtÊ»=-

Gender: MALE!!!
Joined
Jul 25, 2002
Messages
1,678
Location
On Top
Gender
Male
HSC
2002
i dint do sd either...was really lost at start of sem, but den read alot of txtbook and experimented alot and did really well in the end. so deres some incentive for ya.

Originally posted by jlh

he can't post the stuff on the net because its the weekly assignment!! LOL
..sum1 obviosuly hasnt experienced the lvl of plaigarism at mq...
 

jlh

sooner or later...
Joined
Mar 15, 2003
Messages
1,755
Location
Sydney
Gender
Male
HSC
2002
Originally posted by -=MLhtʻ=-
..sum1 obviosuly hasnt experienced the lvl of plaigarism at mq...
LOL.. but i have at usyd!!


i was just looking thru the other assignment, optimize.cpp... i dont' get it... i mean i wrote out my own code and i figure i can just copy+paste it into optimize.cpp, but its stuffed!! where it says to write your code here, if you do that, the cin >> is above it and stuffs it up.. i don't get how he set this thing out.. anyways..
 

pb

Inside The Hollow
Joined
Jan 20, 2004
Messages
775
Location
Westie!
Gender
Female
HSC
2003
i don't get C++ AT ALL... I eventually got how to do Task 2 in the prac and i was sooo proud i was showing off! lol

haha im gonna try to do a C++ tutorial off the net now.

Btw if ur in the prac class on Wednesday morning with the little Asian girl running around asking everyone for help... or err... trying to help (even though i know nothing), come help me lol... cuz there's a 92.57% chance I'll need it.
 

Orange Juice

so worthless i am
Joined
Nov 23, 2002
Messages
3,886
Location
Room 112
Gender
Male
HSC
2007
yeh the weekly isnt as bad as the assignment...

lucky the guy who i have for tutes is a great help
 

jlh

sooner or later...
Joined
Mar 15, 2003
Messages
1,755
Location
Sydney
Gender
Male
HSC
2002
so has anyone got the assignment, optimize.ccp to work yet?

i copied my code over from the one i made.. but when i execute it, i just get this blank screen then i gotta push a letter in for the prompt to come up..... is it just me or did he set it out wrong?
 

bong

Member
Joined
Jun 11, 2003
Messages
433
Gender
Male
HSC
2003
read the faq, a user prompt is not required

so all the code u need to write is the conditions and the corresponding output :)
 

TheDreamer

New Member
Joined
Mar 10, 2004
Messages
20
Thanks Jlh and everyone else!! :)

I've finally started on the assignment and I think I'm actually getting the gist of it. It really isn't that hard after all after you get used to the syntax. Except that doesn't mean I get it right.lol There's basically a few things you got to know for this assigment:

-the variables int
-the const int (typed above int main)
-cin>>x>>y;
-cout<<x<<y;
-" " for quotes and outputs (as jhl pointed out)
-endl; for ending the line

I think. If anyone has anything else to add, please do or correct me, if I'm wrong.

I've still got a question though. It says on the assigment that the input must be the dimensions and output must be the planks.
We can't add any other quotes? such as "The values you entered are..."
 

bong

Member
Joined
Jun 11, 2003
Messages
433
Gender
Male
HSC
2003
Originally posted by TheDreamer
I've still got a question though. It says on the assigment that the input must be the dimensions and output must be the planks.
We can't add any other quotes? such as "The values you entered are..."
no, because apparently that will stuff up the way the computer marking is done,
 

Users Who Are Viewing This Thread (Users: 0, Guests: 1)

Top