program W implicit none character(100)::S integer::i read*,S do i=1,len_trim(S) S(i:i)=char(ichar(S(i:i))+(ichar("A")-ichar("a"))*merge(1,-1,ichar("Z")