Real Vim ninjas count every keystroke - do you?

Pick a challenge, fire up Vim, and show us what you got.

Changelog, Rules & FAQ, updates: @vimgolf, RSS.

Your VimGolf key: please sign in

$ gem install vimgolf
$ vimgolf setup
$ vimgolf put 9v0066fd18cf00000000044d

CaN yOuR ViM dO ThAt? #2

Tsoding's famous "Can your Vim do that?" https://www.youtube.com/watch?v=F4xc4jQO7ck&t=1429s

Start file
Example examples[] = {
    { .src_path   = "./examples/core_basic_window.c", .bin_path   = "./build/core_basic_window", },
    { .src_path   = "./examples/core_basic_screen_manager.c", .bin_path   = "./build/core_basic_screen_manager", },
    { .src_path   = "./examples/core_input_keys.c", .bin_path   = "./build/core_input_keys", },
    { .src_path   = "./examples/shapes_colors_palette.c", .bin_path   = "./build/shapes_colors_palette", },
    { .src_path   = "./examples/tsoding_ball.c", .bin_path = "./build/tsoding_ball", },
    { .src_path   = "./examples/tsoding_snake/tsoding_snake.c", .bin_path = "./build/tsoding_snake", },
    { .src_path   = "./examples/core_input_mouse_wheel.c", .bin_path   = "./build/core_input_mouse_wheel", },
    { .src_path   = "./examples/text_writing_anim.c", .bin_path   = "./build/text_writing_anim", },
};
End file
Example examples[] = {
    {
        .src_path   = "./examples/core_basic_window.c",
        .bin_path   = "./build/core_basic_window",
        .wasm_path  = "./wasm/core_basic_window.wasm",
    },
    {
        .src_path   = "./examples/core_basic_screen_manager.c",
        .bin_path   = "./build/core_basic_screen_manager",
        .wasm_path  = "./wasm/core_basic_screen_manager.wasm",
    },
    {
        .src_path   = "./examples/core_input_keys.c",
        .bin_path   = "./build/core_input_keys",
        .wasm_path  = "./wasm/core_input_keys.wasm",
    },
    {
        .src_path   = "./examples/shapes_colors_palette.c",
        .bin_path   = "./build/shapes_colors_palette",
        .wasm_path  = "./wasm/shapes_colors_palette.wasm",
    },
    {
        .src_path   = "./examples/tsoding_ball.c",
        .bin_path = "./build/tsoding_ball",
        .wasm_path  = "./wasm/tsoding_ball.wasm",
    },
    {
        .src_path   = "./examples/tsoding_snake/tsoding_snake.c",
        .bin_path = "./build/tsoding_snake",
        .wasm_path  = "./wasm/tsoding_snake.wasm",
    },
    {
        .src_path   = "./examples/core_input_mouse_wheel.c",
        .bin_path   = "./build/core_input_mouse_wheel",
        .wasm_path  = "./wasm/core_input_mouse_wheel.wasm",
    },
    {
        .src_path   = "./examples/text_writing_anim.c",
        .bin_path   = "./build/text_writing_anim",
        .wasm_path  = "./wasm/text_writing_anim.wasm",
    },
};

View Diff

2,9c2,41
<     { .src_path   = "./examples/core_basic_window.c", .bin_path   = "./build/core_basic_window", },
<     { .src_path   = "./examples/core_basic_screen_manager.c", .bin_path   = "./build/core_basic_screen_manager", },
<     { .src_path   = "./examples/core_input_keys.c", .bin_path   = "./build/core_input_keys", },
<     { .src_path   = "./examples/shapes_colors_palette.c", .bin_path   = "./build/shapes_colors_palette", },
<     { .src_path   = "./examples/tsoding_ball.c", .bin_path = "./build/tsoding_ball", },
<     { .src_path   = "./examples/tsoding_snake/tsoding_snake.c", .bin_path = "./build/tsoding_snake", },
<     { .src_path   = "./examples/core_input_mouse_wheel.c", .bin_path   = "./build/core_input_mouse_wheel", },
<     { .src_path   = "./examples/text_writing_anim.c", .bin_path   = "./build/text_writing_anim", },
---
>     {
>         .src_path   = "./examples/core_basic_window.c",
>         .bin_path   = "./build/core_basic_window",
>         .wasm_path  = "./wasm/core_basic_window.wasm",
>     },
>     {
>         .src_path   = "./examples/core_basic_screen_manager.c",
>         .bin_path   = "./build/core_basic_screen_manager",
>         .wasm_path  = "./wasm/core_basic_screen_manager.wasm",
>     },
>     {
>         .src_path   = "./examples/core_input_keys.c",
>         .bin_path   = "./build/core_input_keys",
>         .wasm_path  = "./wasm/core_input_keys.wasm",
>     },
>     {
>         .src_path   = "./examples/shapes_colors_palette.c",
>         .bin_path   = "./build/shapes_colors_palette",
>         .wasm_path  = "./wasm/shapes_colors_palette.wasm",
>     },
>     {
>         .src_path   = "./examples/tsoding_ball.c",
>         .bin_path = "./build/tsoding_ball",
>         .wasm_path  = "./wasm/tsoding_ball.wasm",
>     },
>     {
>         .src_path   = "./examples/tsoding_snake/tsoding_snake.c",
>         .bin_path = "./build/tsoding_snake",
>         .wasm_path  = "./wasm/tsoding_snake.wasm",
>     },
>     {
>         .src_path   = "./examples/core_input_mouse_wheel.c",
>         .bin_path   = "./build/core_input_mouse_wheel",
>         .wasm_path  = "./wasm/core_input_mouse_wheel.wasm",
>     },
>     {
>         .src_path   = "./examples/text_writing_anim.c",
>         .bin_path   = "./build/text_writing_anim",
>         .wasm_path  = "./wasm/text_writing_anim.wasm",
>     },

Solutions by @orbitstabilizer:

Unlock 5 remaining solutions by signing in and submitting your own entry
Created by: @Vivida1

9 active golfers, 34 entries

Solutions by @orbitstabilizer:
72
#6 - Yusuf AKIN / @orbitstabilizer

11/09/2024 at 01:21AM

74
#>8 - Yusuf AKIN / @orbitstabilizer

11/09/2024 at 01:15AM

76
#>8 - Yusuf AKIN / @orbitstabilizer

11/09/2024 at 01:19AM

80
#>9 - Yusuf AKIN / @orbitstabilizer

11/09/2024 at 01:11AM

103
#>9 - Yusuf AKIN / @orbitstabilizer

11/09/2024 at 12:56AM