doubt with reading data in the jafra jframe


They could help me with a situation. I have formulated this code to make an alphabet starting from a letter that is written in the jframe. The code is:

        String inicio;
 char[] alfabeto = new char[26];
char  reset1 = 'a';

 public String abecedario (String inicio){
  char pass = inicio.charAt(0);
  pass = (char) (pass-1);
  for (char i=0; i<26;i++)
  alfabeto[i] = (char) (pass+i);
  if (pass == 'z'+1){
  pass = reset1;
 return Arrays.toString(alfabeto);

When executing it in a main class by putting a random letter to start if I get the alphabet ordered from the letter that was written. but when executing it in a jframe I get random values and symbols instead of the alphabet, when I press the button that the alphabet should show, it shows me the value.

  [,  , !, ", #, $, %, &, ', (, ), *, +, ,, -, ., /, 0, 1, 2, 3, 4, 5, 6, 7, 8]

while in main class if I run normal

[j, k, l, m, n, o, p, q, r, s, t, u, v, w, x, y, z, a, b, c, d, e, f, g, h, i] //empezando desde la j

Could you tell me the reason why the value I want in the jframe does not come out please?

asked by LUIS MAYAUTE MALAGA 02.12.2018 в 10:59

0 answers