31 Answers
New Answerhttps://code.sololearn.com/WnQZ0B7qvLjF/?ref=app Adriana#☮️☮️ Here is a code that will help you make turtle codes.
SoloLearn Playground has a different type of Python installed. I tried to pip install turtle using SoloLearn System commands, but it gives object error and its not supported. SoloLearn playground is only capable of running command-line or terminal applications and scripts. It doesn't support turtle as it is not cmd based. The same case happens with tkinter as it is a GUI based module. So the main point is that the SL playground's Python Interpreter doesn't support GUI and graphical scripts and imports
It's not an app, it's a JS framework called Skulpt. It executes Python code to some extent, but the main area that it stands out is its ability to run turtle. Anyways you're welcome Adriana#☮️☮️
The skulpt framework is implemented in its website, which also happens to be a Python interpreter site.
Gamma001 Well she is talking about Python, not other languages. Also, Python isn't compiled, it's interpreted
K.M Ahnaf Zamil I was referring to all the languages, just to clarify why it doesn't work. And I know that python is interpreter based language. If I keep your point and only refer to python it's like talking about an endangered animal dying out in the wild and not talking about how it's entire species is getting extinct. Bad analogy i know, but still... I didn't have any other
Adriana#☮️☮️ sololearn is just for praciticing simple rules, like if, else, for... everything else should be done on your laptop/desktop or at least a mobile app designed to run python codes.
Accept for web, you can't use GUI based libraries or modules in other languages. It's because if the compiler that it uses
Accept for web, you can't use GUI based libraries or modules in other languages. It's because if the compiler that it uses
from math import * print ("Hello sir! welcome to Rabbit calculator...") def options(): print("------------------------------------------------------------------") print("Options: ") print ("------------------------------------------------------------------") print("Enter '+' to add two numbers") print("Enter '-' to subtract two numbers") print("Enter '*' to multiply two numbers") print("Enter '/' to divide two numbers") print("Enter '**' to power two numbers") print("Enter '&' to square root ") print("Enter 'exit' to exit the calculator") print("------------------------------------------------------------------") #divide function def divide(): try: num1, num2 = float(input("Enter first number: ")), float(input("Enter second number: ")) result = num1 / num2 print("The answer: ", result,"\n") except ZeroDivisionError: print ("Error: division by zero is not possible!") divide() finally: x = input ("wanna continue? (y/n) ") if x == "y" or x == "Y": divide() else: exit #Add function def add(): try: num1,num2 = float(input("Enter first number: ")),float(input("Enter second number: ")) result = num1 + num2 print ("The answer: ",result,"\n") except: print ("An error ooccured!") finally: r = input ("wanna continue? (y/n) ") if r == "y" or r == "Y": add() else: exit #Subtract function def subtract(): try: num1, num2 = float(input("Enter first number: ")), float(input("Enter second number: ")) result = num1 - num2 print("The answer: ", result,"\n") except: print ("An error ooccured!") finally: z = input ("wanna continue? (y/n) ") if z == "y" or z == "Y": subtract() else: exit #Multiply function def multiply(): try: num1, num2 = float(i
#divide function def divide(): try: num1, num2 = float(input("Enter first number: ")), float(input("Enter second number: ")) result = num1 / num2 print("The answer: ", result,"\n") except ZeroDivisionError: print ("Error: division by zero is not possible!") divide() finally: x = input ("wanna continue? (y/n) ") if x == "y" or x == "Y": divide() else: exit