Posted By

alejandrosuch on 05/05/10


Tagged

letra dni


Versions (?)

Calcular letra del DNI


 / Published in: Java
 

  1. public String calcularLetraDNI(int dni){
  2. String[] letrasDNI = {"T", "R", "W", "A", "G", "M", "Y", "F", "P", "D", "X", "B", "N", "J", "Z", "S", "Q", "V", "H", "L", "C", "K", "E"};
  3. return (letrasDNI[dni%23]);
  4. }

Report this snippet  

You need to login to post a comment.