Skip to content

Latest commit

 

History

History

zig_lings_example_QandA

Folders and files

NameName
Last commit message
Last commit date

parent directory

..
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Awesome Zig

https://www.trackawesomelist.com/catdevnull/awesome-zig/readme/

Ziglings

https://github.com/ratfactor/ziglings

  • Welcome to Ziglings! This project contains a series of tiny broken programs. By fixing them, you'll learn how to read and write Zig code.

Those tiny broken programs need your help! (You'll also save the planet from evil aliens and help some friendly elephants stick together, which is very sweet of you.)

This project was directly inspired by the brilliant and fun rustlings project for the Rust language. Indirect inspiration comes from Ruby Koans and the Little LISPer/Little Schemer series of books.

Intended Audience

This will probably be difficult if you've never programmed before. But no specific programming experience is required. And in particular, you are not expected to have any prior experience with "systems programming" or a "systems" level language such as C.

Each exercise is self-contained and self-explained. However, you're encouraged to also check out these Zig language resources for more detail:


Zig tutorial part1

Zig Tutorial part 1 __ Simon Clavet




GlobalYoung Youtube

github - Global Young __ zig languages exerciese

Zig Exercieses series

    1. hello zig, std, assignment

한글지그Zig강의_001_hello world_std_assignment_Zig Programming Language tutorial

    1. array

Zig Language Exercises series

한글지그Zig강의 __ 모아 보기 Series Zig Language tutorial



Compiling 030_switch.zig... Checking 030_switch.zig... PASSED: ZIG?

Compiling 031_switch2.zig... Checking 031_switch2.zig... PASSED: ZIG!

Compiling 032_unreachable.zig... Checking 032_unreachable.zig... PASSED: 1 2 3 9 8 7

Compiling 033_iferror.zig... Checking 033_iferror.zig... PASSED: 2<4. 3<4. 4=4. 5>4. 6>4.

Compiling 034_quiz4.zig... Checking 034_quiz4.zig... PASSED: my_num=42

Compiling 035_enums.zig... Checking 035_enums.zig... PASSED: 1 2 3 9 8 7

Compiling 036_enums2.zig... Checking 036_enums2.zig... PASSED:

Red Green Blue

Compiling 037_structs.zig... Checking 037_structs.zig... PASSED: Your wizard has 90 health and 25 gold.

Compiling 038_structs2.zig... Checking 038_structs2.zig... PASSED: Character 1 - G:20 H:100 XP:10 Character 2 - G:10 H:100 XP:20

Compiling 039_pointers.zig... Checking 039_pointers.zig... PASSED: num1: 5, num2: 5

Compiling 040_pointers2.zig... Checking 040_pointers2.zig... PASSED: a: 12, b: 12

Compiling 041_pointers3.zig... Checking 041_pointers3.zig... PASSED: foo=6, bar=11

Compiling 042_pointers4.zig... Checking 042_pointers4.zig... PASSED: num: 5, more_nums: 1 1 5 1

Compiling 043_pointers5.zig... Checking 043_pointers5.zig... PASSED: Wizard (G:10 H:100 XP:20)

Compiling 044_quiz5.zig... Checking 044_quiz5.zig... PASSED: Elephant A. Elephant B. Elephant C.

Compiling 045_optionals.zig... Checking 045_optionals.zig... PASSED: The Ultimate Answer: 42.

Compiling 046_optionals2.zig... Checking 046_optionals2.zig... PASSED: Elephant A. Elephant B. Elephant C.

Compiling 047_methods.zig... Checking 047_methods.zig... PASSED: 5 aliens. 4 aliens. 1 aliens. 0 aliens. Earth is saved!

Compiling 048_methods2.zig... Checking 048_methods2.zig... PASSED: A B C

Compiling 049_quiz6.zig... Checking 049_quiz6.zig... PASSED: A B C Cv Bv Av

Compiling 050_no_value.zig... Checking 050_no_value.zig... PASSED: That is not dead which can eternal lie / And with strange aeons even death may die.

Compiling 051_values.zig... Checking 051_values.zig... PASSED: 1:false!. 2:true!. 3:true!. XP before:0, after:200.

Compiling 052_slices.zig... Checking 052_slices.zig... PASSED: Hand1: A 4 K 8 Hand2: 5 2 Q J

Compiling 053_slices2.zig... Checking 053_slices2.zig... PASSED: 'all your base are belong to us.' 'for great justice.'

Compiling 054_manypointers.zig... Checking 054_manypointers.zig... PASSED: Memory is a resource.

Compiling 055_unions.zig... Checking 055_unions.zig... PASSED: Insect report! Ant alive is: true. Bee visited 15 flowers.

Compiling 056_unions2.zig... Checking 056_unions2.zig... PASSED: Insect report! Ant alive is: true. Bee visited 16 flowers.

Compiling 057_unions3.zig... Checking 057_unions3.zig... PASSED: Insect report! Ant alive is: true. Bee visited 17 flowers.

Compiling 058_quiz7.zig... Checking 058_quiz7.zig... PASSED: Archer's Point--2->Bridge--1->Dogwood Grove--3->Cottage--2->East Pond--1->Fox Pond

Compiling 059_integers.zig... Checking 059_integers.zig... PASSED: Zig is cool.

Compiling 060_floats.zig... Checking 060_floats.zig... PASSED: Shuttle liftoff weight: 1995796kg

Compiling 061_coercions.zig... Checking 061_coercions.zig... PASSED: Letter: A

Compiling 062_loop_expressions.zig... Checking 062_loop_expressions.zig... PASSED: Current language: Zig

Compiling 063_labels.zig... Checking 063_labels.zig... PASSED: Enjoy your Cheesy Chili!

Compiling 064_builtins.zig... Checking 064_builtins.zig... PASSED: 1101 + 0101 = 0010 (true). Furthermore, 11110000 backwards is 00001111.

Compiling 065_builtins2.zig... Checking 065_builtins2.zig... PASSED: A Narcissus loves all Narcissuses. He has room in his heart for: me myself.

Compiling 066_comptime.zig... Checking 066_comptime.zig... PASSED: Immutable: 12345, 987.654; Mutable: 54321, 456.789; Types: comptime_int, comptime_float, u32, f32

Compiling 067_comptime2.zig... Checking 067_comptime2.zig... PASSED: A BB CCC DDDD

Compiling 068_comptime3.zig... Checking 068_comptime3.zig... PASSED: Minnow (1:32, 4 x 2) Shark (1:16, 8 x 5) Whale (1:1, 143 x 95)

Compiling 069_comptime4.zig... Checking 069_comptime4.zig... PASSED: s1={ 1, 2, 3 }, s2={ 1, 2, 3, 4, 5 }, s3={ 1, 2, 3, 4, 5, 6, 7 }

Compiling 070_comptime5.zig... Checking 070_comptime5.zig... PASSED: "Quack." ducky1: true, "Squeek!" ducky2: true, ducky3: false

Compiling 071_comptime6.zig... Checking 071_comptime6.zig... PASSED: Narcissus has room in his heart for: me myself.

Compiling 072_comptime7.zig... Checking 072_comptime7.zig... PASSED: 26

Compiling 073_comptime8.zig... Checking 073_comptime8.zig... PASSED: My llama value is 25.

Compiling 074_comptime9.zig... Checking 074_comptime9.zig... PASSED: My llama value is 2.

Compiling 075_quiz8.zig... Checking 075_quiz8.zig... PASSED: Archer's Point--2->Bridge--1->Dogwood Grove--3->Cottage--2->East Pond--1->Fox Pond

Compiling 076_sentinels.zig... Checking 076_sentinels.zig... PASSED: Array:123056. Many-item pointer:123.

Compiling 077_sentinels2.zig... Checking 077_sentinels2.zig... PASSED: Weird Data!

Compiling 078_sentinels3.zig... Checking 078_sentinels3.zig... PASSED: Weird Data!

Compiling 079_quoted_identifiers.zig... Checking 079_quoted_identifiers.zig... PASSED: Sweet freedom: 55, false.

Compiling 080_anonymous_structs.zig... Checking 080_anonymous_structs.zig... PASSED: [Circle(i32): 25,70,15] [Circle(f32): 25.2,71.0,15.7]

Compiling 081_anonymous_structs2.zig... Checking 081_anonymous_structs2.zig... PASSED: x:205 y:187 radius:12

Compiling 082_anonymous_structs3.zig... Checking 082_anonymous_structs3.zig... PASSED: "0"(bool):true "1"(bool):false "2"(i32):42 "3"(f32):3.14159202e+00

Compiling 083_anonymous_lists.zig... Checking 083_anonymous_lists.zig... PASSED: I say hello!

Compiling 084_async.zig... Checking 084_async.zig... PASSED: foo() A

Compiling 085_async2.zig... Checking 085_async2.zig... PASSED: Hello async!

Compiling 086_async3.zig... Checking 086_async3.zig... PASSED: 5 4 3 2 1

Compiling 087_async4.zig... Checking 087_async4.zig... PASSED: 1 2 3 4 5

Compiling 088_async5.zig... Checking 088_async5.zig... PASSED: Example Title.

Compiling 089_async6.zig... Checking 089_async6.zig... PASSED: .com: Example Title, .org: Example Title.

Compiling 090_async7.zig... Checking 090_async7.zig... PASSED: beef? BEEF!

Compiling 091_async8.zig... Checking 091_async8.zig... PASSED: ABCDEF

답을 다 푼분이 있다. 역시 괴물이 많다. ㅋㅋㅋ