Welcome to Scribd, the world's digital library. Read, publish, and share books and documents. See more
Download
Standard view
Full view
of .
Save to My Library
Look up keyword
Like this
18Activity
0 of .
Results for:
No results containing your search query
P. 1
Aplicatie Java cu fisiere

Aplicatie Java cu fisiere

Ratings: (0)|Views: 2,582|Likes:
Published by deianira
program java care citeste de la tastatura numere si le scrie intr-un fisier;Dupa ce datele au fost scrise,cu un parser StreamTokenizer le afiseaza la terminal
program java care citeste de la tastatura numere si le scrie intr-un fisier;Dupa ce datele au fost scrise,cu un parser StreamTokenizer le afiseaza la terminal

More info:

Categories:Types, School Work
Published by: deianira on Mar 28, 2009
Copyright:Attribution Non-commercial

Availability:

Read on Scribd mobile: iPhone, iPad and Android.
download as PDF or read online from Scribd
See more
See less

06/06/2013

pdf

 
//Aplicatie Java cu fluxuri de intrare si iesire//program care citeste numere de la tastatura si le memoreaza intr-un fisier iesire.txt//apoi,folosind clasa StreamTokenizer parsam datele si le afisam la terminal
import java.io.*;import java.lang.*; public class Aplicatie1 { private BufferedReader tastatura; public static void main (String[] args) {Aplicatie1 a=new Aplicatie1();a.executa();a.executa1();} public void executa() {try {//declaram 2 fisiere si un buffer pt tastaturaFileWriter f1=new FileWriter("iesire.txt");//crearea unui flux de intrare dintr-un fisier care va fi parsat de un StreamTokenizer String vid=" ";tastatura=new BufferedReader(new InputStreamReader(System.in),1);for (int i=1;i<10;i++) {System.out.println("dati un numar:");String sir=tastatura.readLine();f1.write(sir);f1.write(vid);// f1.write(Integer.valueOf(sir));//goleste bufferul de iesire in fisier //String linie=tastatura.readLine();}f1.close(); } catch(IOException e) {System.out.println("eroare");}

Activity (18)

You've already reviewed this. Edit your review.
1 hundred reads
1 thousand reads
Roxana Irimia liked this
Roxana Irimia liked this
Roxana Irimia liked this
Ardeleanu Ancuta liked this
Ioana Cursaru liked this
Ioana Cursaru liked this
Anca Pîntea liked this
Tita Gabriela liked this

You're Reading a Free Preview

Download
/*********** DO NOT ALTER ANYTHING BELOW THIS LINE ! ************/ var s_code=s.t();if(s_code)document.write(s_code)//-->