Book a Demo!
CoCalc Logo Icon
StoreFeaturesDocsShareSupportNewsAboutPoliciesSign UpSign In
microsoft
GitHub Repository: microsoft/vscode
Path: blob/main/extensions/copilot/test/scenarios/test-explain/classes.rb
13397 views
1
# Copyright (c) Microsoft Corporation and GitHub. All rights reserved.
2
3
class MyClass
4
def hello
5
puts "Hello, world!"
6
end
7
end
8
9
class MySecondClass
10
def greet(name)
11
puts "Hello, #{name}!"
12
end
13
end
14
15
my_instance = MyClass.new
16
second_instance = MySecondClass.new
17
second_instance.greet("Alice")
18
19