Advertisement
Guest User

Untitled

a guest
Oct 31st, 2014
185
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
Java 0.59 KB | None | 0 0
  1. package rfop.q1;
  2.  
  3. public class Pessoa {
  4.  
  5.     class arrayPessoa{
  6.         private String[] Nome;
  7.         private String[] MotivList;
  8.         private String[] CausmMort;
  9.         private int[] cpf;
  10.         public arrayPessoa(){ // Pessoa/Construtor
  11.             this.Nome = new String[5];
  12.             this.MotivList = new String[5];
  13.             this.CausmMort = new String[5];
  14.             this.cpf = new int[5];
  15.    
  16.         }          
  17.         public String toString(){ // pecorre as posições de Nome e retorna
  18.                                   //  o que está lá
  19.             String resp = "";
  20.             for(int i=0; i<Nome.length; i++){
  21.                 resp = resp + Nome[i] + "";
  22.             }
  23.             return resp;
  24.         }
  25.  
  26.     }
  27.  
  28.  
  29.  
  30. }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement