#! ruby # yukicoder My Practice # author: Leonardone @ NEETSDKASU ############################################################ def gs() gets.chomp end def gi() gets.to_i end def gss() gs.split end def gis() gss.map(&:to_i) end def nmapf(n,f) n.times.map{ __send__ f } end def ngs(n) nmapf n,:gs end def ngi(n) nmapf n,:gi end def ngss(n) nmapf n,:gss end def ngis(n) nmapf n,:gis end def arr2d(h,w,v=0) h.times.map{[v] * w} end def for2p(hr,wr,&pr) hr.each{|i|wr.each{|j| yield(i,j)}} end def nsum(n) n * (n + 1) / 2 end def vcount(d,r=Hash.new(0)) d.inject(r){|r,e| r[e]+=1;r} end ############################################################ class Abc @@al = ('A'..'Z').to_a def initialize() @a = [1] end def inc() i = 0 loop { @a[i] += 1 break if @a[i] <= 26 @a[i] = 1 i += 1 @a << 0 if @a.size == i } end def to_s() @a.reverse.map{|e| @@al[e-1]}*"" end end n = gi abc = Abc.new n.times {abc.inc} puts abc.to_s