I didn't get any errors but I used a print statement and called the fileexists() method and it returned false but I'm sure the file exists. I've been able to see the image outside the IDE.
Type: Posts; User: cbplayer
I didn't get any errors but I used a print statement and called the fileexists() method and it returned false but I'm sure the file exists. I've been able to see the image outside the IDE.
I'm a newb to GUI and I'm trying to wrap my head around it. I don't quite understand why I am unable to change the frame icon in my GUI application. I chose a picture from "my Pictures" and entered...
I tried you suggestions and although I didn't run into any exceptions, when I tried to print info from the file, I received info that I didn't even put on the file. Can I get help resolving this...
I didn't misspell it. So how do I put the file in its correct location?
import java.io.File;
import java.io.FileNotFoundException;
import java.util.Scanner;
public class TreeDriver {
public static void main(String [] args) {
Scanner input = new...
I currently taking a class on data structures and we had recitation and there are a few questions I don't quite understand how to solve.
Please explain how to do these questions
1.)
(a) [7.5...
I currently taking a class on data structures and we had recitation and there are a few questions I don't quite understand how to solve.
Please explain how to do these questions
1.)
(a) [7.5...
This is a supplementary programming assignment of mine and I have legitimately no idea how to do it even though I've looked online several times and the deadline is soon.I dont have much time b/c...
Anybody??
--- Update ---
I fixed several of the issues but one issue remains. If I input "stay" before I input 'hit" the computer's cards don't print. Please try to help. I really need to get...
Dont my total and values line up with sample output given my the instructor?
Also I fixed some of the issues you mentioned but I'm having trouble with another issue. Sometimes when the play wins,...
Can I please get some help?
Here is one of the outputs:
It worked fine until after the game was over and I prompted the user to say whether or not he wants to play again and when the game restarted, the output displayed "...
Basically I have to write a program that plays the card game, 21.
This is the assignment. I've done most of it but my code has a few issues.
"
PART 1:
You are going to create a simple card...
What do you want me to do?
import java.io.File;
import java.io.IOException;
import java.io.PrintWriter;
import java.util.Scanner;
public class StockAnalysis {
I'm trying to create a method that takes a binary number as a string parameter and then prints out the decimal equivalent. For some reason my code isn't working but I feel like I am extremely close!...
I just want know how to go about implementing crap. I' m basically wondering what kind of methods I should use, etc.
I need to create an output of this nature
javac Craps.java
java Craps
"Pass" line (1) or the "Don't Pass" line (2): 1
Bet: 1
Dice 1: 4 and dice 2: 1. Sum: 5
The button is On. Point: 5....
never mind
It says this method must return a result of type int.
import java.util.Scanner;
public class chap9 {
public static void main (String[] args) {
String message = "statement";
It keeps saying that the method must return a result of type int but I already made return the result.
import java.util.Scanner;
public class chap9 {
public static void main (String[] args)...
I want to pass two arrays into methods that will calculate the averages of the elements in the arrays.
Here is my code.
import java.util.Scanner;
public class Averaginganarray {
public...