Question:
I’m a new coder. I keep getting this when running my program, nix error: building nix env: exit status 1, Output has been trimmed to the last 20 lines. I have no idea why and I’m coding in java. I would really appreciate if the help team could go in and look at my code for me to debug it. Repl link:
Looking at your files and at the hidden file .replit, I cannot find Main.java, which is the file the Repl is attempting to run. If this file does not exist, this is a major problem. I cannot find any .java files.
There’s the missing main file, but also the replit.nix is not set up correctly. But since this looks like a school project I would ask your teacher to fix the Repl or have them get you a new template to work off of.
Thanks for checking that out. If that file doesn’t exist, can I just add it in and name it? Is it something that should’ve come with this project? Because I just opened the link from a Sophia course and so they had setup a file under my account so I could work on this particular project. I guess what are the next steps for me to have it run smoothly?
and in future make sure to watch out for whether text you entered is going into the Console/Shell instead of your files (i.e., the cursor in the Console/Shell is filled)
make sure that all files you want to run have a .java extension and the class you want to run is called Main and not BlackJackSimulation (and so the file must also be called Main.java)