🧙♂️
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| <div class="glassContainer"> | |
| <button type="button" class="glassBtn"> | |
| <svg xmlns="http://www.w3.org/2000/svg" width="24" height="24" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round"> | |
| <path d="M5 12h14"/> | |
| <path d="M12 5v14"/> | |
| </svg> | |
| </button> | |
| </div> | |
| <svg style="display: none"> |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| class SmartDevice: | |
| def __init__(self, brand, model, battery): | |
| """ | |
| Initialize the SmartDevice with common attributes. | |
| """ | |
| self.brand = brand | |
| self.model = model | |
| self.battery = battery | |
| def charge(self): |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| def read_and_write_file(): | |
| filename = input("Enter the filename to read: ") | |
| # Attempt to open the file and read its contents | |
| try: | |
| with open(filename, 'r') as file: | |
| content = file.read() | |
| print("\nOriginal Content:") | |
| print(content) |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| def calculate_discount(price, discount_percent): | |
| # Check if the discount is 20% or more | |
| if discount_percent >= 20: | |
| # Calculate the discounted price | |
| discount_amount = (discount_percent / 100) * price | |
| final_price = price - discount_amount | |
| return final_price | |
| else: | |
| # Return the original price if discount is less than 20% | |
| return price |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| # Step 1: Create an empty list called my_list | |
| my_list = [] | |
| # Step 2: Append the elements 10, 20, 30, 40 to my_list | |
| my_list.append(10) | |
| my_list.append(20) | |
| my_list.append(30) | |
| my_list.append(40) | |
| # Step 3: Insert the value 15 at the second position (index 1) in the list |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| VUE_APP_API_URL=https://api-ssl.bitly.com/v4/shorten | |
| VUE_APP_API_KEY=b4699bd08b3f1b396d7f0b4e98c67b42d98151b1 |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| This extension does not collect, store, or share any personal data. | |
| All settings and preferences are stored locally in your browser. |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Ginger Webs Verificare Business License Key |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| //remember to add {before test} and {after test} to clean up after the test | |
| //your IDE should let you integrate with TestNG, I use NetBeans | |
| @Test | |
| void ClassNameFunctionTest(){ | |
| //code you want to test | |
| } |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| public class LastWordExtractor { | |
| public static String getLastWord(String input) { | |
| // Trim the input string to remove leading and trailing whitespaces | |
| input = input.trim(); | |
| // Find the index of the last space character | |
| int lastIndex = input.lastIndexOf(' '); | |
| // Check if a space was found | |
| if (lastIndex != -1) { |
NewerOlder