32,199 Topics
| |
I could use some assistance My final project in a python class is to calculate the distance between 2 lat/long points. My code is really just managing the input & output portions, while using existing code (properly credited) in a function to do the actual calculations. I've got it working … | |
hi guys how are you all, I sincerely hope that you all christmas is shaping up very good. I am doing my individual assignment, yes another one, a take home this time, I am to implemented a payroll system into a company using a for loop and which i did. … | |
Below is the question from a core java interview. Could somebody please help me? There are designation and employee objects. Designation Employee Designation object --> Designation object is in employee ArrayList<employee> emptemp = new ArrayList<employee>(); emptmp.add(R1); emptmp.add(R2); .. .. .. Now we need to write an helper class or utility … | |
HELLO guys IM beginner using java IM asking what is my problem of my codes?? can you fix it?? import java.applet.Applet; import java.awt.Color; import java.awt.Graphics; public class invalid3 extends Applet implements Runnable { /** * */ private static final long serialVersionUID = 1L; private int x0 , y0 , incx … | |
I am doing this assignment in my Java class. I have never done any programming in my past so I am a complete beginner. I have typed up a program that will ask for employee name, the hourly rate, and the number of hours worked. The program needs to run … | |
My program compiles with no errors, but when I try to use it, the results do not show up and there is an error. Please help!!! import java.awt.*; import java.awt.event.*; import javax.swing.*; import java.text.*; public class RetailSales extends JFrame { // declarations Color black = new Color(0, 0, 0); Color … | |
How do i put a flag on location that the user right click on it. and how do i put an img to all mine in game board when game is end? I try to put an img but wont work? How can i fix it? here is what a … | |
Can someone please! Fix this for me? My program : loop reads 10 double numbers after that inserts them into an array list. after that print MAx and MIn And AVg THIS MY PROGRAM WHY I CAN NOT MAKE COMPILE Fix this for me : import java.util.Scanner; import java.util.ArrayList; import … | |
Is string primitive value in java? What is difference between primitive value and primitive data type in java? Thanks in advance. | |
Row 1[ item1, item2, item 3, item 4, item 5, item 6, item 7, item 8] Row 2[ item1, item2, item 3, item 4, item 5, item 6, item 7, item 8] Row 3[ item1, item2, item 3, item 4, item 5, item 6, item 7, item 8] Row 4[ … | |
Example of problem: Pattern one is: 1, 10, 1: 1 Pattern two is: 10, 10, 10: 0 From this extremely simple pattern we will know that a small value followed by a large increase and then a large decrease means it is a 1. Otherwise its a 0. Using something … | |
hii I have a list having m1 m2 m3........ m922 and in each there are a1 a2 a3 a4 are there like m1=a1 a2 a3 a4 a5 a6 m2=a1 a2 a3 a4 a5 a6 m3=a1 a3 a5 a7 a8 a2 etc and i want this as m1=a1 a2 a3 a4 … | |
Hello i need some help on what to add to the following if statement for the out put to read the value of sum times the actual number of sum: public class ICMA42 { /* instance variables */ private int alpha; private int bravo; private int sum; /** * Constructor … | |
public class ICMA42 // instance variables - replace the example below with your own private int alpha; private int bravo; private int sum; /** * Constructor for objects of class sum which initialises sum to 0. */ public ICMA42() { this.alpha = 0; this.bravo = 0; this.sum = alpha + … | |
Following Error is shown well going to DGFT India Site. How to Resolve ERROR WHILE SENDING OUTPUT access denied ("java.net.SocketPermission" "164.100.128.143:8100" "connect,resolve") | |
Hey Guys, I am building app using a huffman tree, and am building this java program to just test a few things and I am having some trouble. I have everything working except that I am having troble decompressing a huffman string back into the original string. I would appreciate … | |
Is there a way to calculate large numbers without using BigInteger? I am calculating an exponent without using the math class. | |
I am having problems with it continuous loop at the end of the program. Any help would be appreciated. Thank you. Below is the coding so far. [CODE]import static java.lang.System.out; import java.util.Scanner; import java.io.*; public class Investment { public static void main(String[] args) { double principal = 0; double interest … | |
hi all I have a question. I am still trying to build this game/program but I declared a console and was told to import it which i did, the problem is that I am constantly getting an error line underneath the console, can u guys tell me why is that. … | |
Hi, If you look trough my code you can see that i have tried to print out some values (the mean value) with a scanner from a csv file with the help of an enhanced for loop (the absolut last loop) and it gives me NaN (not a number). And … | |
I am trying to convert my code into generic and I get an error at o1 + o2 stating that cannot find symbol for o1 and o2 then bad operand types for binary operator on the push(pop()+ pop()). public abstract class MyStackGeneric <E> extends ArrayList <E> { protected abstract E … | |
Hi! Newbie Java Programmer here! I've done a cash register program. this error's pretty unusual to me. i dont know how to fix this. import java.text.*; import javax.swing.*; import java.awt.*; public class CashRegisterV1 { public static void main (String[] args) { DecimalFormat fix = new DecimalFormat("0.00"); //QUANTITIES int Nido = … | |
so i need help on Modifying the source code to sort on the Title (in ascending order) and display the book title, comma space, author’s first name, comma space, author’s last name. Ensure all your variable names are appropriately named. and i also need help Modifying the source code to … | |
I'm trying to use this code, but it will only display the image in jtextpane and it does not display the text. JLabel label = new JLabel("<html>some text here<img src='http://www.yoursie.com/image.jpg'></html>"); then using this label in JTextPane. | |
in java jframe swing how i can use system default scrollbar style? eg. the default style looks like [this](http://i.imgur.com/3wrBufN.png). | |
double sum = 0; double d; for (d = 0; d < 10; d = d + 0.1 ) { sum = sum + d; } The program has a syntax error because the semicolons in the for loop are in the wrong place. The program has a syntax error … | |
I have one question, when you want to add a game round in a java game, how do you do it, do you use the round().method or do you simply put (round++) + 1? | |
hello!I install tomcat server and set CLASSPATH variable `servlet-api` and my servlets running properly but when i compile and run my old program program of `java 2 SE` then it compile successfully but not run it prints an error message G:\Java>javac BinarySearchDemo.java G:\Java>java BinarySearchDemo Error: Could not find or load … | |
Scanner input = new Scanner(System.in); String secretWord ; String guess, dash = "-", upWord; int numGuesses = 0; int numWord; final String SENTINEL = "!"; System.out.println("Player 2, please look away. Player 1, please enter the secter word: \n"); secretWord = input.next().toUpperCase().trim(); numWord = secretWord.length(); for(int dashNum = 1; dashNum < … | |
Hello, I have problem with jbotton. I have botton decalre it. but how do i access it ? because I have 10X10 or 100 botton. let i want to access 95 botton how can i do that? how do i set the title? here is code import java.awt.*; import javax.swing.*; … |
The End.