LINUX.ORG.RU

История изменений

Исправление theNamelessOne, (текущая версия) :

(fn greet String (name &str)
    (format! "Hello, {}!" name))

(fn main ()
    (let* ((name "World")
           (greeting String (greet name)))
      (println! "{}" greeting)))

Исходная версия theNamelessOne, :

(fn greet String (name &str)
    (format! "Hello, {}!" name))

(fn main ()
    (let* ((name "World")
           (greeting (greet name)))
      (println! "{}" greeting)))