1
0
Fork 0
forked from fun/fun

Added base64 example. Lot of refactoring. (0.37.49)

This commit is contained in:
Johannes Findeisen 2026-01-14 01:57:57 +01:00
commit 75538e6142
17 changed files with 439 additions and 45 deletions

View file

@ -0,0 +1,29 @@
#!/usr/bin/env fun
/*
* This file is part of the Fun programming language.
* https://fun-lang.xyz/
*
* Example: Demonstrate hidden input (no echo) for passwords.
*
* Added: 2026-01-02
*/
#include <io/console.fun>
print("=== input_hidden() example ===")
c = Console()
username = c.ask("Username")
password = c.ask_hidden("Password")
// Do not print the password; just show the username
print(join(["Hello, ", username, "!"], ""))
/* Expected output:
Username: hanez
Password:
=== input_hidden() example ===
Hello, hanez!
*/