C++ help! ;<

Questions about programming languages and debugging
Post Reply
User avatar
ayu
Staff
Staff
Posts: 8109
Joined: 27 Aug 2005, 16:00
18
Contact:

C++ help! ;<

Post by ayu »

Could somebody help me with this?, i get weird errors (will point out the errors)

[Note that i just woke up and i think i have been staring at this code for to long now.....]

Code: Select all

Stupid html tag filter -.-

http://juhtryukcom/codec.txt
"The best place to hide a tree, is in a forest"

User avatar
Nerdz
The Architect
The Architect
Posts: 1127
Joined: 15 Jun 2005, 16:00
18
Location: #db_error in: select usr.location from sucko_member where usr.id=63;
Contact:

Post by Nerdz »

I gtg sleep, but I'll chek it tomorrow. I've read it very fast and the first error is is weird... first

int antal,arr,tal,position=0,temp,j,nr=0;; why 2 ; ?
arr = new int[antal]; //ERROR 1

You should write something like

int arr * = null; or somthing like this for the syntax to declare a pointer and then allocate memory with: arr = new int[antal];

In your while looping, try to use eof -> http://www.cplusplus.com/reference/iost ... s/eof.html

I haven't tried to compile anything... as I said, tomorrow I'll check it.
Give a man a fish, you feed him for one day.
Learn a man to fish, you feed him for life.

Post Reply