ARRRRRG. So stupid. Problem solved.
When I was adding my hashes to the arrays I was adding references to references.
Ie:
I was doing:
Code:
push(@input,/$hash);
Code:
push(@input,$hash);
Jake
push(@input,/$hash);
push(@input,$hash);
for(my $i=0; $i<@input; $i++){
my $hash = $input[$i];
print "$i: \n";
print "\t".'$hash = ';
print $hash;
print "\n\t".'${$hash} = ';
print("@input");
print(@input)
for(int i=0; i<array.length;i++){
System.out.print(array[i]);
System.out.println();
int & f()
{
int c=4;
return c;
}
int main()
{
int b=f();
cout<<b;
}
int & f()
# reads words from the input file def readWords(): jake = sys.stdin listOfWords= jake.readlines() listOfWords = [i[:-1] for i in listOfWords] return listOfWords
def readWords(): while 1: line = raw_input() if line != "": listOfWords.append(line); else: break #End read words method
li = []
for i in range(0,9): #<- these must be the correct range.
temp = raw_input("")
li.append(temp)
Leave a comment: