Advertisement
Guest User

Untitled

a guest
Nov 15th, 2018
95
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 1.22 KB | None | 0 0
  1. using System;
  2. using System.Collections.Generic;
  3. using System.IO;
  4. using System.Linq;
  5. using System.Text;
  6. using System.Threading.Tasks;
  7.  
  8. namespace Manevra
  9. {
  10. class Jucator
  11. {
  12. private string nume;
  13. private string post;
  14. private string cnp;
  15.  
  16. public string getNume { get { return nume; } }
  17. public string getPost { get { return post; } }
  18. public string getCnp { get { return cnp; } }
  19.  
  20.  
  21. private int varsta;
  22. private string data_nasterii;
  23. private string echipa;
  24.  
  25.  
  26. public Jucator(string nume,string post,string cnp,string echipa)
  27. {
  28. this.nume = nume;
  29. this.post = post;
  30. this.cnp = cnp;
  31. this.echipa = echipa;
  32. salveaza_fisier();
  33. }
  34. public Jucator(string nume,string post, string cnp)
  35. {
  36. this.nume = nume;
  37. this.post = post;
  38. this.cnp = cnp;
  39. }
  40. public void salveaza_fisier()
  41. {
  42. StreamWriter sw = new StreamWriter("E:\\LPF\\" + echipa + "\\" + cnp + ".lpf", false);
  43. sw.WriteLine(nume);
  44. sw.Write(post);
  45. sw.Close();
  46. }
  47.  
  48. }
  49. }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement