From 63a43d79dd044a1126da2541d8d80171a33dd81c Mon Sep 17 00:00:00 2001 From: LordBaryhobal Date: Tue, 2 Jun 2026 13:07:53 +0200 Subject: [PATCH] chore: update examples --- examples/01_simple_type_checking/02_simple_types.midas | 6 +++--- examples/01_simple_type_checking/03_control_flow.py | 9 ++++++++- 2 files changed, 11 insertions(+), 4 deletions(-) diff --git a/examples/01_simple_type_checking/02_simple_types.midas b/examples/01_simple_type_checking/02_simple_types.midas index eee3eb9..6a1a6a2 100644 --- a/examples/01_simple_type_checking/02_simple_types.midas +++ b/examples/01_simple_type_checking/02_simple_types.midas @@ -1,6 +1,6 @@ -type Meter(float) -type Second(float) -type MeterPerSecond(float) +type Meter = float +type Second = float +type MeterPerSecond = float extend Meter { op __add__(Meter) -> Meter diff --git a/examples/01_simple_type_checking/03_control_flow.py b/examples/01_simple_type_checking/03_control_flow.py index 90f5530..772c9ac 100644 --- a/examples/01_simple_type_checking/03_control_flow.py +++ b/examples/01_simple_type_checking/03_control_flow.py @@ -4,13 +4,20 @@ def minimum(x: int, y: int): else: return y + a = 15 b = 72 c = minimum(a, b) + def factorial(n: int) -> int: if n <= 1: return 1 return n * factorial(n - 1) -category = "Category 1" if a < 10 else "Category 2" \ No newline at end of file + +category = "Category 1" if a < 10 else "Category 2" + + +def foo() -> None: + pass