Write a program to print Z,z,X,x,V,v,T,t,R,r,..............uptil A,a.
Input Format
#
Constraints
#
Output Format
Print the series in a single line as given below. Z,z,Y,y,X,x,W,w,V,v,U,u,T,t,S,s,R,r,Q,q,P,p,O,o,N,n,M,m,L,l,K,k,J,j,I,i,H,h,G,g,F,f,E,e,D,d,C,c,B,b,A,a.
Z,z,Y,y,X,x,W,w,V,v,U,u,T,t,S,s,R,r,Q,q,P,p,O,o,N,n,M,m,L,l,K,k,J,j,I,i,H,h,G,g,F,f,E,e,D,d,C,c,B,b,A,a.
import java.io.*; import java.util.*; import java.text.*; import java.math.*; import java.util.regex.*; public class Solution { public static void main(String[] args) { for(int i='Z'; i>='A'; i--){ if(i!='A'){ System.out.print((char)(i)+","); System.out.print((char)(i+32)+","); } else{ System.out.print((char)(i)+","); System.out.print((char)(i+32)+"."); } } }
}
Also Read: WAP to Print Fibonacci series 2