Jump to content
xisto Community

arijitsinha99

Members
  • Content Count

    10
  • Joined

  • Last visited

Everything posted by arijitsinha99

  1. AnglingCatching of fish is one of the more popular form of recreation. Angling is the act of fishing with a hook and line and usually a rod.Sportfishing is understood to have begun in mid-15th century. The true angler fishes for the love of fishing. Modern sportfishing can be divided into two basic categories: freshwater fishing and saltwater fishing. The three most common fishing tactics are bait fishing (ofter called still ? fishing in England), spin fishing and fly ? fishing.Bait fishing involves the use of live or dead bait on hook, with a short rod, a reel, and heavy line. Depending on the species that the angler hopes to catch, the bait site on the bottom where fish may feed, bobs up and down off the bottom so that the action may attract fish; or is reeled a good distance off the bottom to attract fish schooled at mid-depth. Anglers frequently tie a leader (a short length of steel wire or heavy nylon) between the hook and the regular nylon or Dacron fishing line to prevent the fish from biting through the line. Lines for all types of fishing come in various diameter or strength, and anglers choose them according to the size and strength of the fish being sought. Spin fishing, which uses somewhat longer rod than bait fishing, is more often associated with artificial lures. Fly-fishing uses a rod much longer- up to 3 m(10 ft)-and lighter than rods used for bait and spin fishing. Dry-fly fishing used files that float on the top of the water ; wet-fly fishing uses flies that sink.
  2. Dear Friends I am sharing a java program with all of u which I built a few years back. I guess it will help beginners. It uses java utill package to store data in a flat file. The File Name-----phone.java { System.out .println("Enter the 'ID', 'q' for quit _linenums:0'>import java .io .*;import java .util .*;import java.awt.event.*;public class phone { public void new_record() { String id,name,city,add,number,total,list; boolean bln=false; try { Properties pr=new Properties(); FileInputStream fin=new FileInputStream("phone.dat"); if(fin!=null) { pr.load(fin); } BufferedReader br1=new BufferedReader (new InputStreamReader(System.in)); FileOutputStream fout=new FileOutputStream("phone.dat"); for(; { System.out .println("Enter the 'ID', 'q' for quit:"); id=br1.readLine().toUpperCase(); bln=pr.containsKey(id); System.out .println("FLag"+bln); if(bln) { System.out.println("ID id already exists, Please Enter another ID:"); continue; } if((id.toUpperCase()).equals("Q")) break; System.out.println("enter name:"); name=br1.readLine().toUpperCase(); System.out.println("enter Phone number:"); number=br1.readLine().toUpperCase(); System.out.println("enter address:"); add=br1.readLine().toUpperCase(); System.out.println("enter city:"); city=br1.readLine().toUpperCase(); total=" Name="+name+","+"Phone no="+number+","+" Address="+add+","+" City="+city; total=total.toUpperCase(); pr.put(id,total); pr.store(fout,"My Telephone Book"); } fout.close(); } catch(Exception e) { System.out.println(e); } } public void display_record() { String id=""; String total=""; int x=1; try { FileInputStream fin=new FileInputStream("phone.dat"); Properties pr1=new Properties(); pr1.load(fin); Enumeration enum1=pr1.keys(); while(enum1.hasMoreElements()) { id=enum1.nextElement().toString(); total=pr1.get(id).toString(); StringTokenizer stk=new StringTokenizer(total,"=,"); System.out .println("RECORD ::"+x+"\n"); x++; while(stk.hasMoreTokens()) { String key=stk.nextToken(); String value=stk.nextToken(); System.out.println("\t"+key+"::\t\t::"+value); try { Thread.sleep(1500); } catch(Exception e){} } System.out.println(""); System.out.println(""); } fin.close(); } catch(Exception e){} } public void display_by_name() { String name="",id,total; String key[]=new String[4]; String value[]=new String[4]; int i=0; System.out.println("Enter Name For Searching Record :-"); try { BufferedReader br=new BufferedReader(new InputStreamReader(System.in)); name=br.readLine().toUpperCase(); FileInputStream fin=new FileInputStream("phone.dat"); Properties pr1=new Properties(); pr1.load(fin); Enumeration enum1=pr1.keys(); while(enum1.hasMoreElements()) { id=enum1.nextElement().toString(); total=pr1.get(id).toString(); StringTokenizer stk=new StringTokenizer(total,"=,"); while(stk.hasMoreTokens()) { for(i=0;i<4;i++) { key[i]=stk.nextToken(); value[i]=stk.nextToken(); } if(value[0].equals(name)) { for(i=0;i<4;i++) { System.out.println("\t"+key[i]+":"+value[i]); try { Thread.sleep(1500); } catch(Exception e){} } } } System.out.println(""); } fin.close(); } catch(Exception e){ System.out.println(e); }} public void display_by_city() { String city="",id,total; String key2[]=new String[4]; String value2[]=new String[4]; int i=0; System.out.println("Enter City For Searching Record :-"); try { BufferedReader br=new BufferedReader(new InputStreamReader(System.in)); city=br.readLine().toUpperCase(); FileInputStream fin=new FileInputStream("phone.dat"); Properties pr1=new Properties(); pr1.load(fin); Enumeration enum1=pr1.keys(); while(enum1.hasMoreElements()) { id=enum1.nextElement().toString(); total=pr1.get(id).toString(); StringTokenizer stk=new StringTokenizer(total,"=,"); while(stk.hasMoreTokens()) { key2[i]=stk.nextToken(); value2[i]=stk.nextToken(); // System.out.println("aaaaaaaaaaaaaaa"+value2[i]); if(i==3) { if(value2[i].equals(city)) { for(int j=0;j<4;j++) { System.out.println("\t"+key2[j]+":\t"+value2[j]); try { Thread.sleep(1500); } catch(Exception e){} } } } i++; if(i>3) i=0; } System.out.println(""); System.out.println(""); } fin.close(); } catch(Exception e){ System.out.println(e); } }public void display_record_first_letter() { String name="",id,total,str=""; String key2[]=new String[4]; String[] value2=new String[4]; int i=0; try { BufferedReader br=new BufferedReader(new InputStreamReader(System.in)); System.out.println(" Enter The First Letter Of any Name:"); name=br.readLine(); name=name.substring(0,1).toUpperCase(); FileInputStream fin=new FileInputStream("phone.dat"); Properties pr1=new Properties(); pr1.load(fin); Enumeration enum1=pr1.keys(); while(enum1.hasMoreElements()) { id=enum1.nextElement().toString(); total=pr1.get(id).toString(); StringTokenizer stk=new StringTokenizer(total,"=,"); while(stk.hasMoreTokens()) { for(i=0;i<4;i++) { key2[i]=stk.nextToken(); value2[i]=stk.nextToken(); } str=value2[0].substring(0,1); if(str.equals(name)) { for(i=0;i<4;i++) { System.out.println("\t"+key2[i]+":\t"+value2[i]); try { Thread.sleep(1500); } catch(Exception e){} } } } System.out.println(""); System.out.println(""); } fin.close(); } catch(Exception e){ System.out.println(e); }} public void replace_record() { String id,name,city,add,number,total,list; boolean bln=false; try { Properties pr=new Properties(); FileInputStream fin=new FileInputStream("phone.dat"); if(fin!=null) { pr.load(fin); } BufferedReader br1=new BufferedReader (new InputStreamReader(System.in)); FileOutputStream fout=new FileOutputStream("phone.dat"); for(; { System.out .println("Enter the 'ID', 'q' for quit:"); id=br1.readLine().toUpperCase(); if((id.toUpperCase()).equals("Q")) break; bln=pr.containsKey(id); if(bln) { System.out.println("ID id already exists, "); System.out.println("enter name:"); name=br1.readLine().toUpperCase(); System.out.println("enter Phone number:"); number=br1.readLine().toUpperCase(); System.out.println("enter address:"); add=br1.readLine().toUpperCase(); System.out.println("enter city:"); city=br1.readLine().toUpperCase(); total=" Name="+name+","+"Phone no="+number+","+" Address="+add+","+" City="+city; total=total.toUpperCase(); pr.put(id,total); pr.store(fout,"My Telephone Book"); } else { System.out.println("ID does'nt Exists, Please Enter A Valid ID:"); continue; } } pr.store(fout,"My Phone Book"); fout.close(); } catch(Exception e) { System.out.println(e); } } public void delete_record() { String id=""; boolean bln=false; try { Properties pr1=new Properties(); FileInputStream fin=new FileInputStream("phone.dat"); if(fin!=null) pr1.load(fin); BufferedReader br1=new BufferedReader (new InputStreamReader(System.in)); FileOutputStream fout=new FileOutputStream("phone.dat"); for(; { System.out .println("Enter the 'ID', 'q' for quit:"); id=br1.readLine().toUpperCase(); if((id.toUpperCase()).equals("Q")) break; bln=pr1.containsKey(id); if(bln) { System.out.println("ID exists :"); String str=pr1.remove(id).toString(); pr1.store(fout,"My Phone Book"); try { Thread.sleep(1500); } catch(Exception e){} System.out.println("Record deleted successfully"); } else { System.out.println("Enter Existing ID:"); pr1.store(fout,"My Phone Book"); } } pr1.store(fout,"My Phone Book"); fin.close(); fout.close(); } catch(Exception e) { System.out.println(e); } } public void menu() { char ch=30; char ch1=31; int l; for(int i=0;i<27;i++) { System.out.print(" "); } for(l=0;l<2;l++) { for(int j=0;j<38;j++) { System.out.print(ch); } System.out.println(""); for(int k=0;k<27;k++) { System.out.print(" "); } } System.out.print(ch); System.out.print(ch1); for(int i=0;i<34;i++) System.out.print(" "); System.out.print(ch); System.out.print(ch1); System.out.println(""); for(int i=0;i<27;i++) System.out.print(" "); System.out.print(ch); System.out.print(ch1+" "); System.out.print (" 1. Enter new Record: "); System.out.print(" "+ch); System.out.println(ch1+" "); for(int i=0;i<26;i++) System.out.print(" "); System.out.print(" "+ch1); System.out.print(ch+" "); System.out.print (" 2. Display All Record: "); System.out.print(" "+ch); System.out.println(ch1+" "); for(int i=0;i<26;i++) System.out.print(" "); System.out.print(" "+ch); System.out.print(ch1+" "); System.out.print (" 3. Search Record by name: "); System.out.print(" "+ch); System.out.println(ch1+" "); for(int i=0;i<26;i++) System.out.print(" "); System.out.print(" "+ch); System.out.print(ch1+" "); System.out.print (" 4. Search Record by city: "); System.out.print(" "+ch); System.out.println(ch1+" "); for(int i=0;i<26;i++) System.out.print(" "); System.out.print(" "+ch); System.out.print(ch1+" "); System.out.print (" 5. Search Record by 1st letter:"); System.out.print(" "+ch); System.out.println(ch1+" "); for(int i=0;i<26;i++) System.out.print(" "); System.out.print(" "+ch); System.out.print(ch1+" "); System.out .print(" 6. Replace Record: "); System.out.print(" "+ch); System.out.println(ch1+" "); for(int i=0;i<26;i++) System.out.print(" "); System.out.print(" "+ch); System.out.print(ch1+" "); System.out .print(" 7. Delete Record: "); System.out.print(" "+ch); System.out.println(ch1+" "); for(int i=0;i<26;i++) System.out.print(" "); System.out.print(" "+ch); System.out.print(ch1+" "); System.out .print(" 8. Exit: "); System.out.print(" "+ch); System.out.println(ch1+" "); for(int j=0;j<27;j++) System.out.print(" "); System.out.print(ch); System.out.print(ch1); for(int i=0;i<34;i++) System.out.print(" "); System.out.print(ch); System.out.print(ch1); System.out.println(""); for(int i=0;i<27;i++) System.out.print(" "); for(int i=0;i<38;i++) System.out.print(ch); System.out.println(""); for(int i=0;i<27;i++) System.out.print(" "); for(int i=0;i<38;i++) System.out.print(ch); } public static void main (String[] args) { phone cl=new phone(); BufferedReader br; for(; { try { cl.menu(); br=new BufferedReader (new InputStreamReader(System.in)); System.out.print(" Enter Your Choice :"); String choice=br.readLine(); if(choice.equals ("1")) { cl.new_record(); } else if(choice.equals("2")) { cl.display_record(); } else if(choice.equals("3")) cl.display_by_name(); else if(choice.equals("4")) { cl.display_by_city(); } else if(choice.equals("5")) cl.display_record_first_letter(); else if(choice.equals("6")) cl.replace_record(); else if(choice.equals("7")) cl.delete_record(); else if(choice.equals("8")) System.exit(0); } catch(Exception e){} } }} Notice from BuffaloHELP: You must use HTML or CODEBOX (for long codes like this) for all html codes. You should not be receiving hosting credits for codes entered.
  3. great buddy.....very nice . Its been a great help to me . I always wondered how these are mady. Thank u again and keep up the good work..hey buddy great stuff. I liked the way u simply tought us. I always wondered about how to build these. but u did it very easyly. keep up ur good work buddy....hope to hear from u soon. bye..
  4. Dear Friends This is a free fileupload script written in ASP. I found this script a few month back on internet. So I just want to share it with u. You are requested to leave the copy rights Intect Notice from saint-michael: If you are going ot copy scripts from another website they must be put in quotes since its not your original work. Credits reduce.
  5. Dear Friends Come 9th June Fifa world cup 2006 is going to be held. So I am posting a match schedule for all of u and I wish u happy viewing..... Notice from BuffaloHELP: Use QUOTE tag next time when copying from another source. We have dedicated SPORTS section. Please search the forum before you make your topic!
×
×
  • Create New...

Important Information

Terms of Use | Privacy Policy | Guidelines | We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.