結果
| 問題 | 
                            No.138 化石のバージョン
                             | 
                    
| コンテスト | |
| ユーザー | 
                             Rin
                         | 
                    
| 提出日時 | 2015-09-05 17:59:09 | 
| 言語 | Scheme  (Gauche-0.9.15)  | 
                    
| 結果 | 
                             
                                WA
                                 
                             
                            
                         | 
                    
| 実行時間 | - | 
| コード長 | 656 bytes | 
| コンパイル時間 | 35 ms | 
| コンパイル使用メモリ | 5,120 KB | 
| 実行使用メモリ | 16,000 KB | 
| 最終ジャッジ日時 | 2024-07-19 03:52:23 | 
| 合計ジャッジ時間 | 2,411 ms | 
| 
                            ジャッジサーバーID (参考情報)  | 
                        judge1 / judge4 | 
(要ログイン)
| ファイルパターン | 結果 | 
|---|---|
| sample | AC * 3 | 
| other | AC * 27 WA * 6 | 
ソースコード
(define (System.out.println x)
  (begin
    (display x)
    (newline)
  )
)
(define (ver2num x)
  (let loop(
            (i 0)
            (RetVal 0)
           )
    (if (= i (- (length x) 1))
        RetVal
        (if (string=? (list->string (list (list-ref x i))) ".")
            (loop (+ i 1) (* RetVal 1000))
            (loop (+ i 1) (+ (* RetVal 10) (string->number (list->string (list (list-ref x i))))))
        )
    )
  )
)
(let (
      (X (string->list (symbol->string (read))))
      (Y (string->list (symbol->string (read))))
     )
  (if (>= (ver2num X) (ver2num Y))
      (System.out.println "YES")
      (System.out.println "NO")
  )
)
            
            
            
        
            
Rin