Hi guys, im needed help with a compile error I'm getting for my code. I am using a scanner to read a dat file I already made with values from -1.0 and 1.0, but the problem I am getting is where I declare (below) the file to the console. The error I am getting is saying that it can't find the symbol, for the variable sounds1. Wondering what I was doing wrong here? It is declared in my main so theoretically it should work, but I have looked in the books and it looks the same. I'll put the first skeleton code so you can better understand my thinking behind my work. Thanks guys! I know posting help for assignments is frowned upon, but I'm not asking for help writing my code or anything just help and a little guidance thanks!!
Joined: Jun 22, 2012
Solved it!! Moved the File filein above the sounds1 and sounds 2 I put it in the wrong order so the doubles were trying to get info from nowhere. And When I was getting errors for sounds1 in the classes for printA and init A I didnt switch the sounds1.length to a.length so it was syntactically incorrect and wouldn't correct. Here is the new code that compiles.