32,199 Topics

Member Avatar for
Member Avatar for NA

i want to show my graph values but its show null output. i show you in image output also // JavaScript Document $(document).ready(function(){ $.ajax({ url: "data.php", method: "GET", success: function(data) { console.log(data); var playerid = []; var score = []; for(var i in data) { playerid.push("Player " + data[i].playerid); score.push(data[i].score); …

Member Avatar for stultuske
0
355
Member Avatar for Aakanksha_1

import java.util.ArrayList; import java.io.*; import java.util.*; import java.util.Graph; public class Graph { public int[][] adjMatrix;//Edges will be represented as adjacency Matrix int size; } public Graph(int size) { adjMat = new boolean[size][size]; for (int i=0; i < adjMat.length; i++) { for (int j=0; j < adjMat.length; j++) { adjMat[i][j] = …

Member Avatar for AssertNull
0
449
Member Avatar for Stefano Mtangoo
Member Avatar for Aakanksha_1

public class Graph { boolean[][] adjMat; // In the adjacency matrix representation of a Graph, // if adjMat[i][j] == true, then you can move from // node i to node j. // i.e. j is a neighbour of i. // The constructor builds the adjacency matrix, // with initially all …

Member Avatar for JamesCherrill
0
419
Member Avatar for Jeanyl_1

Gud day geeks! This is intended for my thesis! We are creating our own Computer laboratory management with network monitoring system from the computer laboratory users. I would like to know is there other references aside with the wireshark? I've been searching for a month now, the other sources does …

Member Avatar for rproffitt
0
195
Member Avatar for saurabh.mehta.33234

I am trying to learn Volatile keyword in Multi Threading and I came across this statement: *Volatile is preferred in cases when one thread reads and writes a shared variable and other threads just read the same. Whereas if there are more than 2 threads performing read and write both …

Member Avatar for JamesCherrill
0
207
Member Avatar for manalibhadula

Below program in completly executing but no data was inserted through sqlloader. Inline Code Example Here public class CSVDataLoad { public void runSqlldr () throws InterruptedException { String[] stringCommand = { "bash", "-c", "/usr/bin/sqlldr username/password@sid control=/path/to/sample.ctl"}; System.out.println("SQLLDR Started"); Runtime rt = Runtime.getRuntime(); Process proc = null; try { proc = …

Member Avatar for Didier_2
0
5K
Member Avatar for saurabh.mehta.33234

I am trying to understand the SynchronizedMap and I ran the below code. I get the below Output with an exception. According to my understanding the exception is caused when the get() methods are trying to access the syncmap when a thread is still executing a write on the map …

Member Avatar for JamesCherrill
0
740
Member Avatar for scheppy

I was wondering what would be the best way to implement an algorythm to figure out what side a circle has collided with a rectangle? After check to make sure a circle has collided with the rectangle im trying to figure out how to know what side of the rectangle …

Member Avatar for scheppy
0
4K
Member Avatar for divinity02

hi everyone I am currently practicing my java skills by doing this program called car rental management system. I am creating a login page where when the user login it should bring up a dashboard. but the problems when the user login and it say "credentials match, the dashboard doesnt …

Member Avatar for rproffitt
0
319
Member Avatar for Horse_1

Hai Sir, I am confused while creating Invoice system how to add the products item for Single invoice, and save it in MYSQL data base? Thanks and Regards, S. Hari ari

Member Avatar for stultuske
-1
153
Member Avatar for whitejag

I bought a web site a few months ago thinking that I could go to a community tech school. I have not found the classes that I need. So I don't know how to build it. Help?

Member Avatar for rproffitt
0
200
Member Avatar for saurabh.mehta.33234

In the below code about the synchronisation between threads, according to the output generated why is the control being transferred to the execution of the new thread despite the lock being acquired for the same object "dt" in the main method ? public class DemoThread extends Thread { public DemoThread() …

Member Avatar for JamesCherrill
0
235
Member Avatar for saurabh.mehta.33234

I am trying to run the below concurrency code: import java.util.concurrent.ExecutorService; import java.util.concurrent.Executors; import java.util.concurrent.TimeUnit; public class TestThread { public static void main(final String[] arguments) throws InterruptedException { ExecutorService executor = Executors.newSingleThreadExecutor(); try { executor.submit(new Task()); System.out.println("Shutdown executor"); executor.shutdown(); executor.awaitTermination(5, TimeUnit.SECONDS); } catch (InterruptedException e) { System.err.println("tasks interrupted"); } finally …

Member Avatar for JamesCherrill
0
424
Member Avatar for scheppy

Hi Guys, Im currantly having a problem with simulating balls bouncing of each other in a 2d space, everything is working and all, but it just doesant seem natural for me... If we had any math wizzes here now is your time please:) my circles are painted inside of rectangles..... …

Member Avatar for scheppy
0
3K
Member Avatar for Luca_1

Hey guys, I am at the very beginning of learning Java and my task right now is to code a maze (2D Array) and let a bot automatically solve that maze using only the right hand rule. If I let the programm run it prints out an infinite number of …

Member Avatar for rproffitt
0
451
Member Avatar for Saboor880

Hi I have made a desktop application and i have to print some data to printer.For this purpose I have done my code and ran it successfuly and test on xps doucuments and on oneNote . I have no physical printer but i am satisfied by testing it on xps …

Member Avatar for rproffitt
0
313
Member Avatar for scheppy

Hi Guys Its me again, wasnt sure if i should start a new thread so i just did :) I completly redid the code Now im having a problem with the renderer again. It called called in the timer of the controller class... but it doesant get called? Also my …

Member Avatar for scheppy
0
464
Member Avatar for Joe_10

I am trying to follow the sample of the barcode reader from codelabs. However I am stuck, could someone help me out please. [Codelabs tutorial](https://codelabs.developers.google.com/codelabs/bar-codes/#0) I have updated the manifests to include the vision libaries. import android.app.Activity; import android.graphics.Bitmap; import android.graphics.BitmapFactory; import android.graphics.drawable.BitmapDrawable; import android.os.Bundle; import android.util.SparseArray; import android.view.View; import …

Member Avatar for rproffitt
0
641
Member Avatar for scheppy

Currantly trying to make a simple game but i cant get the renderer to repaint. My problem is that i used to make everything in 1 class... much simpler. But now im just not sure anymore. This is what i have so far... it just wont repaint. (Note i have …

Member Avatar for scheppy
0
1K
Member Avatar for Saboor880

Hi! I have developed a desktop application in java. Now I want to do payment integration with this app. Actually I have to do payment integration for first time in my life. So i have some questions/confusions for payment integration. But before asking those questions I tell you that what …

Member Avatar for Saboor880
0
431
Member Avatar for Rafin Ishraq
Member Avatar for scheppy

Hi Guys Just starting to make my first java game, im getting a few errors. Im just trying to figure a few things about about the game loops before i get started and this is driving me crazy when i just call the renderer to repaint after i initialize the …

Member Avatar for scheppy
0
1K
Member Avatar for Addvantum
Member Avatar for John_165

Hi guys , is me again ! I get stucked on this question Write a program that read an integer and display its smallest prime factors in ascending order. For example, if the input is 60, the output should be 2,3,5... I came out with below code, but I get …

Member Avatar for rproffitt
0
407
Member Avatar for Prosatanos

It sorts names in ArrayList, but how exactly does it happen? public void sortStudentsAlphabetic() { int i, j; Student temp; Student[] array = new Student[studentsList.size()]; for (int k = 0; k < array.length; k++) { array[k] = studentsList.get(k); } for (i = 0; i < array.length - 1; i++) { …

Member Avatar for JamesCherrill
0
185
Member Avatar for John_165

Use a **for** loop to find the smallest integer n such that n^3 is greater than 1000 So I came out with below code public class Chapter4 { static int n = 0; public static void main(String[] args) { for (int i = 1; Math.pow(i, 3) <= 1000; i++) { …

Member Avatar for rproffitt
0
1K
Member Avatar for Bensaber

Hello, I'm new in java programming, i have insert amounts in database in this Format exp : 1.100.200,00 but the subtraction of this amount give false result . here is part of my code DecimalFormat df = new DecimalFormat(); DecimalFormatSymbols symbols = new DecimalFormatSymbols(); symbols.setDecimalSeparator(','); symbols.setGroupingSeparator(' '); df.setDecimalFormatSymbols(symbols); statement = …

Member Avatar for Bensaber
0
303
Member Avatar for ibenwa

hello please i need help, am writing a project to check if a particular folder exist in client system , if not let it create it, but if found let it delet it from client side immediately the client visit the site. i try this on my localhost it work …

Member Avatar for JamesCherrill
0
192
Member Avatar for laguardian

So, I've created a program that when a user inputs a type of vehicle, it will print how much will the user pay for their fare. Here's what I have so far: How do I call the methods Vehicle, Vehicle1, etc.. so that I am able to print the fare …

Member Avatar for stultuske
0
3K

The End.