|
-
Nov 28th, 2005, 04:37 PM
#1
Thread Starter
New Member
( or [ expected
Hi all,
Just wondering if anyone could help. I'm writing a small mulichoice quiz progrmam but i can't seem to get an arraylist to hold my questions. I recieve
from the class that creates the arraylist to hold the questions. I can't seem to spot what i've done wrong.
Code:
import java.util.ArrayList;
public class Quiz
{
public Quiz()
{
Questions = new ArrayList<String>();
}
}
Regards,
Last edited by pthug; Nov 28th, 2005 at 04:42 PM.
-
Nov 28th, 2005, 08:18 PM
#2
Fanatic Member
Re: ( or [ expected
First off, Questions is not declared. Or am I missing something?
Edit: Or I assume you're using Java compiler lower than 5, yet you're using a Java 5 compliant syntax.
Last edited by nebulom; Nov 28th, 2005 at 09:10 PM.
-
Nov 29th, 2005, 01:11 AM
#3
Re: ( or [ expected
The problem is: you are using old version of java, you must have java 1.5
"I'm not normally a praying man, but if you're up there, save me... Superman!" - Homer Simpson
My Blog
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules
|
Click Here to Expand Forum to Full Width
|