This comment is reply for 838 iwk: (アルファベットの繰り上がり). Go to thread root.
iwk #843(2007/07/14 12:56 GMT) [ OCaml ] Rating0/0=0.00
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16
open System;; open Char;; open String;; open List let transAlph n = let base = 26 in let zero = (code 'A')-1 in let rec transBase results = function | m when m <= base -> m::results | m when m%base = 0 -> transBase results (m/base) | m -> transBase ((m%base)::results) ((m-m%base)/base) in String.concat "" (map (fun x -> of_char (chr (zero+x))) (transBase [] n));; printf "%s\n" (String.concat "," (map transAlph (init 100 (fun x->x+1))));;
Rating0/0=0.00-0+
[ reply ]
iwk
#843()
[
OCaml
]
Rating0/0=0.00
Rating0/0=0.00-0+