Thank you!!!
Type: Posts; User: felixb
Thank you!!!
ok, but do you have an idea how can i link between the trees?
but if i have 3 persons for example:
id = 1, addr = z st
id = 2, addr = h st
id = 3, addr = a st
the id's tree will be like: (if i sort it by the id...)
2
1 3
...
my PERSON type have ID, fname, lname, address
and I built one tree that have that type.
you mean I should build 4 trees (1- ID, 2 - fname, 3 - lname, 4 - address) instead?
how will i do the link...
how to do it?
yes, the "DATA" of the tree is PERSON type (that i create) that have the following information about each person: ID, fname, lname, address.
the tree sorted by the ID
but also i want to search by...
The structure should support small and very large number of records.
The Tree already supports the search (quick and eddicient) records by key field, the ID Number of structure person).
What I'm...
Hello,
I am writing a program that maintains basic information about people (each person have id num, first name, last name).
I keep all the data using a binary tree, which DATA is PERSON type...
you are right, thnk's for your help.
by post 3 do you mean - SuperMarket_demo.java? if is - so it do execute...
about the constructor, this is the empty constructor
public void SuperMarket()
{
this.name = null;...
from the console window:
"
Enter supermarket details:
Enter name:
my
How many products do you have:
2
Exception in thread "main" java.lang.NullPointerException
at...
ok, this is the full source's
ProductType.class
import java.io.BufferedReader;
import java.io.InputStreamReader;
import java.io.FileReader;
import java.io.IOException;
why not? the function is in class Supermarket that have an empty constructor:
public void SuperMarket()
{
this.name = null;
this.products = new ArrayList<ProductType>();...
Hi,
I have 2 classes:
1) productType that have name and price of the productType and an empty consturcor.
2) superMarket that have name of supermarket and arraylist of productTypes (
private...
Hello,
I have some java projects in eclipse.
I want to organize the projects into some folders in the Package Explorer.
How can I do it? (I tried to add new folder, but it ask me to choose one...
sorry, my mistake. it's print exactly 4.
thnks
hi
i run the following code:
Math.pow(2,2)
why the output is 4.012 and not 4?
ok, i moved it to the catch section.
now it sees to be good.
thnk you
it run, but incorrect.
if i give 5 incorrect input - it run good, give 5 tries and exiting program after the 5 th attemp.
if i give 4 incorrect and the last is correct - it give 4 tries, i the 5 th...
Hi,
I try to write piece of code that get input from the user and in case of wrong input give the user anoter chance (total of 3 tries) to type input again.
what is the problem with it?
this...
Thanks
Hello,
I have this part of source code
for(int i=0;i<num;i++)
{
System.out.println("Recored number: " + i+1 + " is:");
....
Hi,
I'm trying to write little program that get input from the user (using BufferedReader and readLine() function) the program should run till the user type 'quit'.
so i write something like...