32,199 Topics

Member Avatar for
Member Avatar for Yutxz

I received the error "possible loss of precision" on the last line of my code. Is it not possible to return a double? My instructions were to create a program, called power, that took a double (x) and raised it to an integer (n) power. [CODE] package power; /** * …

Member Avatar for Yutxz
0
194
Member Avatar for ncstplaya1234

[LIST=1] [CODE] System.out.print("Enter the letter(t or z): "); B]letter = keyboard.next();[/B] if (letter == 't'||letter == 'T') { System.out.println("True"); } else if (letter == 'z'|| letter == 'Z') { System.out.println("False"); } [/CODE] Im getting an error here in bold, what is the problem??

Member Avatar for Akill10
0
77
Member Avatar for nwalser

Ok so I have to write a reverse method of a stack and I am not quite sure how to do it. I understand that i need to pop the strings from one stack into another but whenever I try to do this errors arise. Specifically it says it cannot …

Member Avatar for cale.macdonald
0
831
Member Avatar for baldturtle

When i try to complile it says SlotMachineReel.java:175: missing return statement I think its because all my returns are in "if" statements and it needs a default return. line 128 & line 175 Thanks in advance for any help [CODE]/** * Constructs a new reel with its current face randomly …

Member Avatar for baldturtle
0
159
Member Avatar for jems5

I would like to sort a list (from a text file "sales.txt")that has text, int and float values. The problem I have is, my output only produces the last set of values. I would like to produce a table with as the final output. Please help me. [CODE]public class Sales …

Member Avatar for jems5
0
161
Member Avatar for kchadek

So I need to write test cases for a problem with multiplying, dividing, adding, & subtracting fractions but I just can't quite seem to get it correct that it works. Here is part of the test file [CODE]//Multiply if (f1.multiply(f2) == (-2/15)) { System.out.println("test multiply: passed"); } else { System.out.println("test …

Member Avatar for kchadek
0
104
Member Avatar for ramjeev

Hi everyone, I want to disable windows key in keyboard.Please let me know if u hav any idea.

Member Avatar for oknight
0
65
Member Avatar for sijothomas

Hi friends ...... I am doing a priject based on face recognation in java .... If anybody knows about it please help me....my doubts are:- 1-how can i read inage from a web cam ? 2-give a best and latest algorithm for comparingtwo images Anyway thanks in advance...May GOD bless …

Member Avatar for cale.macdonald
0
69
Member Avatar for gedas

hey guys, i am looking for source code as simple as possible that would be able to represent the shape of the human body in 3d (it could be almost stick man like or preferably something like this [url]http://www.3dlinks.com/oldsite/tutorials/GENERAL/chapter6_1.cfm[/url]) i would like to use for further development such as a …

Member Avatar for gedas
0
446
Member Avatar for Tiff22

Project 1 Project 1: Moving Objects Objectives Upon Completion of this project, students will be able to : Implement small classes that conform to a set specification. Use multiple classes together to solve a larger problem. Use logic to enforce a valid internal state and perform computations. Description The purpose …

Member Avatar for Katana24
-1
83
Member Avatar for cool girl

I have so much trouble with this questions not only questions I want to study big o and time complexity but until now I didn’t found any good sit that explained it so could anyone help me by proved some sits about big o and time complexity and I really …

Member Avatar for kramerd
-1
157
Member Avatar for doctorjo5

There are already 2 checkboxes to change to bold and italic. Now I want to make four radio buttons to change the font of the saying "say it with style!". Below is my code. [CODE]//******************************************************************** // StyleOptionsPanel.java Author: Lewis/Loftus // // Demonstrates the use of check boxes. //******************************************************************** import javax.swing.*; …

Member Avatar for kramerd
0
2K
Member Avatar for boiishuvo

When I tried to compile this code, it has one error says ThreadsDemo.java:37: 'else' without 'if' else { ^ I don't know what's wrong with that exactly? [CODE]import java.util.*; class A extends Thread { private static int counter=0; private final int id=++counter; A() { start(); } public void run() { …

Member Avatar for JamesCherrill
0
85
Member Avatar for Dean_Grobler

Hi there, In the code below my ImageIcon isn't showing when I run the program. I always struggle with adding Images in my GUIs and it's irritating. Is there some all important rule that I should know or something? [CODE] //Create window Components JLabel lblrequest = new JLabel("Enter amount of …

Member Avatar for JamesCherrill
0
4K
Member Avatar for Mega brains

I am developing a java application that should run entirely from a CD. I should not install anything on the machine but now I am in need of a database. Is there any DB that I could use to sort out my problem? Thank you.

Member Avatar for Ezzaral
0
74
Member Avatar for dalip_007

Hi Guys I require a Java applet (and web service on server) permitting upload of large files to the server. Client side: The applet UI should simply permit selection of a file for upload from the local directory structure. The server URL will be hard-coded in the applet. When the …

Member Avatar for dalip_007
0
153
Member Avatar for jemimaloh

Hi there. I am currently trying programme my code[COLOR="Red"](P)[/COLOR] to lookup a hashtable from another class[COLOR="Green"](F)[/COLOR]. IS that possible? Given that the hashtable is in the main method of [COLOR="Green"](F)[/COLOR]. Should I apply a toString() in [COLOR="Green"](F)[/COLOR] and make it a String variable before I call it into[COLOR="Red"](P)[/COLOR]? If I …

Member Avatar for jemimaloh
0
516
Member Avatar for AirGear

I want to add sound in my Java program. I searched in Internet, and what I found was only how to add sound to java applet. Isn't there any way to insert sound into the desktop application java? Thanks in advance Regards, AG

Member Avatar for AirGear
0
137
Member Avatar for sivasuit
Member Avatar for MargaretAlbert

How do [B][URL="http://www.improsys.com/importer.htm"]IMPROSYS[/URL][/B] use Contact Importer JAVA in a JSP page? <%@ page language="java" contentType="text/html" %> <% String user = request.getParameter("user"); %> <% String password = request.getParameter("password"); %> <% String parser = request.getParameter("parser"); %> <% String userId = "";%> <% if(user == null) user = ""; if(password == null) password …

0
55
Member Avatar for nizam27391

hello.. i'm new and still learning netbeans.. i use netbeans as my mini project for my java course.. but here's what i dont understand.. i design using GUI.. i make black background... when i click on preview design.. everything seems ok and it look exactly like what i want.. but …

0
83
Member Avatar for python01

hi all, im fairly new to python and am struggling to find out how to read javascript values from a site. Help is much appreciated. thanks, Python01

Member Avatar for python01
0
228
Member Avatar for pentagenius

Hi all, I am having a problem with threads as demonstrated below: I have four very small and simple files. They are as follows: [CODE] 1) public class MainClass { private static SchedulerTest sch = null; public static void main(String[] args) { try{ sch = new SchedulerTest(); ThreadController tc = …

Member Avatar for ashams001
0
190
Member Avatar for kchadek

Ok so I'm brand new to programming and Java so go easy on me. The assignment is to take fractions and do all the operations to them, add, subtract, multiply, and divide. We are also required to do this with a test file and then the actual file. So far …

Member Avatar for kchadek
0
85
Member Avatar for Radio2006

I am trying to start this java program using the requirements below, but I have no idea where to start. Just so you guys know, I am just starting out in this language. i have experience in Javascript programming, but this is completely different. I am used to Java programs …

Member Avatar for Radio2006
0
243
Member Avatar for charat

So i am a college student and my assignment is to create a code that determines if an entered number is a palindrome or not. the assignment is as follows: "Write the following two methods: //Return the reversal of an integer, i.e. revers(456) returns 654 public static int reverse(int number) …

Member Avatar for weathernerd1990
0
3K
Member Avatar for rayden150

I created a little beginners program, and its about a Telephone network which has an operator and three clients: i made four classes, and it gives me error at planta and cliente In cliente it gives error on public class cliente private operadora Im Planta it gives me error in …

Member Avatar for kramerd
0
135
Member Avatar for DivineRose

Hello, everyone! I have a really basic Triangle program that I have to make (no applets or Scanner, just calculating), but I have no idea of where to start. I'm supposed to compute the lengths of the sides, the angles, the perimeter, and the area. Right now, I'm stuck on …

Member Avatar for DivineRose
0
105
Member Avatar for dmor574

Hey, this is my first post, and i'm a complete noob at Java. (i don't exactly know if i did the 'code tags' correctly, so if it didn't work properly, just know that I tried. my basic question is this: I'm trying to make a program that runs fullscreen on …

Member Avatar for dmor574
0
114
Member Avatar for babyboy70

can someone help me write a java program that reads the inputted text and checks to see if any uppercase letters where used.

Member Avatar for kramerd
0
53

The End.