Skip to content

urschrei/rust_fizzbuzz

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

23 Commits
 
 
 
 
 
 
 
 

Repository files navigation

WHAT (May 18th, 2015)

An update of Lindsey Kuper's excellent Rust FizzBuzz using Rust 1.x, as a way of taking some tentative first steps towards learning the language.

The by_reference branch contains a variant which passes the results of the division operations to int_to_rem by reference, where they're destructured. Note that this isn't necessarily more efficient or flexible, however, since i32 is a primitive type, and thus implements the Copy trait.

This approach to solving FizzBuzz using Rust is by no means the fastest way to do it (see Chris Morgan's explorations for more), but I find this implementation particularly intuitive, and well-suited to the language.

About

Implementing FizzBuzz using Rust 1.0

Topics

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages