Skip to content

Instantly share code, notes, and snippets.

View AstragoDE's full-sized avatar

AstragoDE AstragoDE

View GitHub Profile
for i in range(1, 101):
# `and`-Bedingung hinzugefügt, damit "Fizz" **Ausschließlich** bei `i % 3 == 0` ausgegeben wird.
if i % 3 == 0 and i % 5 > 0:
print("Fizz")
# `and`-Bedingung hinzugefügt, damit "Buzz" **Ausschließlich** bei `i % 5 == 0` ausgegeben wird.
if i % 5 == 0 and i % 3 > 0:
print("Buzz")
if i % 5 == 0 and i % 3 == 0:
@AstragoDE
AstragoDE / README.md
Created April 8, 2023 14:51
Commonly used Rust commands (by ChatGPT)

Cargo Commands

Command Description
cargo new Create a new Rust project
cargo build Build the Rust project
cargo run Build and run the Rust project
cargo test Run tests in the Rust project
cargo doc Generate documentation for the Rust project
cargo clean Clean the target directory of the Rust project
@AstragoDE
AstragoDE / README.md
Last active April 8, 2023 17:34
Dataypes in Rust (by ChatGPT)

Signed Integer Types:

Type Minimum Value Maximum Value
i8 -128 127
i16 -32,768 32,767
i32 -2,147,483,648 2,147,483,647
i64 -9,223,372,036,854,775,808 9,223,372,036,854,775,807

Unsigned Integer Types:

| Type | Minimum Value | Maximum Value |