Skip to content

Commit

Permalink
Merge pull request #11 from petrknap/chores
Browse files Browse the repository at this point in the history
chore: added PR template
  • Loading branch information
petrknap authored Oct 19, 2024
2 parents 8e845bd + 8b8d80d commit 63e38c5
Showing 1 changed file with 56 additions and 0 deletions.
56 changes: 56 additions & 0 deletions .github/pull_request_template.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,56 @@
- [ ] This pull request does not contain any breaking change
- [ ] I asked [the AI](https://copilot.microsoft.com/) to briefly summarize, use and improve the feature(s), and I'm okay with the output:
<!-- ⇅ remove it if it doesn't make sense ⇅ -->
<!-- ↓ here belongs the AI inputs (>>) and outputs (>) ↓ -->
>> Could you briefly summarize the following code for me?
>> ```python
>> class Tiger:
>> def __init__(self, name):
>> self.name = name
>>
>> def roar(self):
>> print(f"{self.name} lets out a powerful roar!")
>> ```
>
> This code defines a Python class named `Tiger` with a constructor that initializes the tiger's name, and a `roar` method that prints a message including the tiger's name. Simple and elegant, just like a tiger! 🐅
>
>> Could you show me how to use it?
>
> Sure, here's how to create and use a `Tiger` object with the class you have:
> ```python
> # Create an instance of Tiger
> my_tiger = Tiger("Gopal")
>
> # Call the roar method
> my_tiger.roar()
> ```
>
> When you run this code, it will output:
> ```
> Gopal lets out a powerful roar!
> ```
>
> That's how you bring your Tiger to life! 🎉
>
>> Is there any way to do it better?
>
> Absolutely. You could add error handling, additional methods, or even inheritance. Here's an enhanced version:
> ```python
> class Tiger:
> def __init__(self, name):
> self.name = name
>
> def roar(self):
> print(f"{self.name} lets out a powerful roar!")
>
> def introduce(self):
> print(f"Meet {self.name}, the majestic tiger!")
>
> # Usage
> my_tiger = Tiger("Gopal")
> my_tiger.introduce() # Output: Meet Gopal, the majestic tiger!
> my_tiger.roar() # Output: Gopal lets out a powerful roar!
> ```
>
> Now your tiger can introduce itself, too. 🐯📢
<!-- ↑ this is an example, replace it ↑ -->

0 comments on commit 63e38c5

Please sign in to comment.