Baseline: tree as shared
This commit is contained in:
1679 files changed
+1024562
No files matched your search
@@ -0,0 +1,13 @@
|
||||
struct LidarScan(Copyable, Movable):
|
||||
var near_points: Int
|
||||
|
||||
def __init__(out self, near_points: Int, far_points: Int):
|
||||
self.near_points = near_points
|
||||
|
||||
def total(self) -> Int:
|
||||
return self.near_points + self.far_points
|
||||
|
||||
|
||||
def main():
|
||||
var scan = LidarScan(8, 256)
|
||||
print("Total points:", scan.total())
|
||||
Reference in new issue
Block a user