32,199 Topics
| |
I came across a KMeans implementation in Java. The number of clusters generated by the code is 3. But when I tried to change it to 2, I am getting the error: Exception in thread "main" java.lang.ArrayIndexOutOfBoundsException: 2 Any help is much appreciated. Here is the code: public class KMeans … | |
this is what i have so far. public class PersonalInformation{ /* =================================================== ===== Challenge 6.1 - Personal Information Class ===== ====================================================== Design a class that holds the following personal data: name, age, and phone number. Write appropriate accessor and mutator methods. Demonstrate the class by writing a program that creates … | |
Need help with two classes "Cannonball Component" and "Cannonball" I couldn't figure out the code with the rest but. Feel free to look at code check : http://codecheck.it/codecheck/files?repo=bj4fp&problem=ch06/c06_exp_6_16 | |
Easy tutorial: https://slicker.me/javascript/tower.htm | |
Hi i'm a beginner in Java. I have school assigment where they want to save employee array to the file and can load it back with replacing the current array in GUI when it hit button save or load. Also, if i want to save or load the array with … | |
I 'm building an application to store and retrieve books, but I have an issue with retrieving data from the db. I'm using REST and testing with postman. Everything works OK. Currently I have a series of methods written in Java at the backend like so @Override @POST @Path("/add") //@Produces("application/json") … | |
Write a Java application that calculates the number of repayments for a loan based on the initial loan amount, annual interest rate and monthly payment. The user enters these values and application uses a loop to display the balance each month after payment has been made. Note that interest is … | |
Heres an example since A is a square matrix while B and C is not. The program on my head is a row and a colum counter then if the row and colum is equal to eachother then the system will print out that the A matrix is a square … | |
JQ is taking a car trip with his family. On the trip, he will stop for fuel, food or lodging. When stopping for gas, JQ will record the amount of fuel he is willing to pay for. When the family stops for lodging, they will also have a meal. JQ … | |
I have an existing text file with a list of book names. I want to read those names & write a second text file with the names of duplicate entries. For example: SamsBookstore.txt might have And Then It's Spring Baby Bear Sees Blue Beach Feet Jimmy the Greatest! Boot & … | |
hello can anybody help me with this issue i have java code to print information that exists in XML file i will paste it here, so i want to print the information based on user input , as example the user enter the Id number then the program should print … | |
| |
How can i make codes for this? Problems for Program Development 1. Create a java program that will display a menu for choices to perform the following routines: 1. Input a number then determine and display the factors of the number. 2. Input a number then determine and display if … | |
I want this kind of output How? output: Enter a number: 3456 Digit(s): 3 4 5 6 | |
Hiii How are you every one im very happy to be here with all of you & i hopeto enjoy our time togather Thanks :) | |
import random money = 100 Ask user if they want to play or "QUIT" (.upper()) while game != "QUIT": 2 dice generate random numbers 1-6 on each (generate random numbers inside while loop) Every roll cost $3 Win $5 if total is 7 Win $10 for snake eyes Else display … | |
What are the top learning management systems for corporations? And how it helps for employee training? | |
Hey guys I'm having trouble figuring out how to calculate the standard divination of an array in Java. As you can see I have already calculated the mean, and I know that at the end I will have to divide by the sample size minus 1 (n-1) and square that … | |
I am writing a Mastermind program in Java. So the user has to enter the number of pegs and colors and a code will randomly be generated and the program will do its thing and tell them if they got the code or not. I have a bunch of IF … | |
| def fib(num): if num<=1 return num return fib(num - 1) + (num - 2) num = int(input("enter a number higher than 0: ")) print(fib(i)) |
Hi All, I would personally looking for someone from the US for a partnership. This will be something like a part-time job that needs 5 hrs per week. Requirements: US citizenship for legal issues. Basic understanding of technical - Junior Full-stack (web and mobile development) Experience working remotely. Open-minded and … | |
data1,true,2000,422 data2,false,2001,421 data3,true,2050,427 data4,true,2004,432 the above data is in sample.txt. I want to write a program using a for loop and any filereader class or by any means, such that my output will be stored in as follows: My_Data[1]= data1,true,2000,422 My_Data[1][0]= data1 My_Data[1][1]= true My_Data[1][2]= 2000 My_Data[2]= data2,false,2001,421 My_Data[2][0]= data2 … | |
Java is necessary in every field. | |
I want to compute e^x= 1+x/1!+x^2/2!+x^3/3!+...+x^n/n! For any given value of x and n | |
Hi to all! I am making an android app for a ready made social medial website. Website url is: "www.MixMasala.in" I am using webview for this site, all the functionality working accept two. As this is a social media website it has also audio and video calling option. When I … | |
I am writing a program that uses a while loop to determine the largest number input so far. I have to input 10 numbers in whole. At the end of the loop, it should output the largest number. [CODE]import java.util.Scanner; public class Largest { public static void main(String[] args) { … | |
I got a java programming assignment in where you will ask: 1.) Ask the user to input item name, price, quantity and payment. 2.) Store the responses in the computer's memory. 3.) Displaying the item name, total amount and change. ( PS: Still new to this site, want some help … | |
Hello, I have been using the JDoddle online IDE for Java programming: https://www.jdoodle.com/online-java-compiler/ I am unable to increase the font of the Java output terminal. Can that be done? Thank you | |
The End.