So are we creating an instance for a class domestically? - Becaus main is defined in the same class..
Based on what you taught, this is best and simplest i could come up with:
import java.util.*;...
Type: Posts; User: KSR
So are we creating an instance for a class domestically? - Becaus main is defined in the same class..
Based on what you taught, this is best and simplest i could come up with:
import java.util.*;...
Hi Junky,
yes you are right... And thankyou so much to elaborate on the concept.. So i cannot use an instance in a static void main.. So i removed my void main (since my compiler would not take a...
Hi Junky,
Im really viewing this from C++ perspective, since i am not @ alll fluent with java..
On solving my previous error, i got an error saying:
" Line: 8
non-static variable list cannot...
H,,
i got it.. public should be all low case.
ta,
KSR
Hi..
Thankyou for the reply,, but where exactly am i using the wrong case, im not able to figure out.
Thanks for helping.
import java.util.*;
public class Arraylistcollection
{
ArrayList<Integer> list = new ArrayList<Integer>();
Public static void main (String args[])
{
//Numberinglist(list);
int total = 0;...