Set<String> PropType = new HashSet<String>();
for (int j = 0; j < cols; j++){
PropType.add(line[1][j]);
}
Iterator Prop = PropType.iterator();
while(Prop.hasNext()){
System.out.print(Prop.next());
}
Tried to run this code...but it keeps giving the error:
Exception in thread "main" java.lang.NullPointerException
Any suggestions?
for (int j = 0; j < cols; j++){
PropType.add(line[1][j]);
}
Iterator Prop = PropType.iterator();
while(Prop.hasNext()){
System.out.print(Prop.next());
}
Tried to run this code...but it keeps giving the error:
Exception in thread "main" java.lang.NullPointerException
Any suggestions?
