I can't run turtle in vs code - turtle-graphics

Please I have a problem. I'm trying to run turtle module in VS Code but when I run it, a have every time an error. Can you say me what is my error ?enter image description here

Related

Lua unexpected identifier issue in VSC

i was transfering code from my tablet's ide to VSC to tweak it and continue it on PC but i've ran into an issue. I'm trying to define a variable by using local xyz = 0 but it keeps returning SyntaxError: Unexpected identifier when i try to run it but it worked perfectly fine on my mobile IDE. (on pc i'm using Visual Studio Code with the Lua extension by sumneko and on pc i was using an app called TouchLua+)debug console output
i've tried looking it up on google but there were no posts describing any similar issue
It's hard to say without more code or context(not familiar with the touchapp) but this as a standalone piece of lua is valid.
However notice your debug screenshot, you are executing a piece of lua with nodejs, Look at the cli
C:\ProgramFiles\nodejs\node.exe RPSbot.lua
^ ^
| |
Path to node |
your lua file given to the node.exe
Unsure if there is some other js process that you used on your tablet that ran lua via nodejs or you are trying this from js yourself. But nodejs is intended for javascript files.
Using node on this piece of code produces the same error. You should run this using the lua runtime. If you haven't already, you can download lua here, be sure to add it to your path if needed.
Then you can run it from cli as following:
lua RPSbot.lua
Or create a batch script to call it by name without lua before it, i.e. create a file called RPSbot.cmd or RPSbot.bat and place calling code in it lua RPSbot.lua. The calling code might need to use the full path to lua and your script. Then you can just run that batch script each time.
If it is intended to run trough node you might need to provide more code and/or context.
Use Zerobranestudio or jdoodle. I give up to compile Lua with vsc.

Kernel died restarting jupyter notebook

While executing python code in Jupyter notebook,"kernel died and restarting jupyter notebook" error occurred.The code uses opencv library.
This might not be quite relevant to your case but it might be relevant to someone else. I had the same problem...2 potential causes: using quit() command in Jupyter. The second cause in my case was using Pandas: display(df)...I think that the cause could be triggered by an output is that is too large to display (e.g. very large text output). I suggest the following approach: run the program on a line by line basis till you find the exact line causing the problem. This is how I found out that display(df) is what was breaking Jupyter...when I took this line out the program ran without problems. If you have a large output display part of it, not all.

How to run Derric

I'm trying to run Derric with command
import lang::derric::testparse;
I followed all instructions and got everything to work with eclipse and Rascal. I am running the rascal console with Derric. I have tried downloading older versions of eclipse, used windows 7, and windows 10. Nothing is working, I even read the rascal tutorial on modules to see if everything looks right and it does. I need it to work for a school assignment, if someone can get it to run can you tell me under which circumstances (i.e eclipse version, windows version, steps taken) to run the program?
rascal>import lang::derric::testparse;
Error: Cannot import module lang::derric::testparse
Time: 484ms
ok
rascal>
It's suppose to say ok at the end, and then I can run command generate().
Hi #yoyo great that you are trying Rascal, but you need to give more explanation about what you are trying to do. There are potentially two main causes of the message you get:
the module is correct but it cannot be found, or
the module is incorrect (e.g. it does not even parse correctly).
It would therefore be helpful if you show
where lang::derric::testparse is located in your file system, and
to show its contents.
As a side question: is there any relation with the Derric language (a DSL for file formats) Jeroen van den Bos has been working on a few years ago?

Lua obfuscator, how to

I understand this question will appear silly but I'm clueless what to do, which makes it even more silly. I have written a lua script for a game - which works, but I've never actually run any lua with the lua programs(from the site download). I would like to obfuscate my lua code with this tool: https://github.com/mlnlover11/XFuscator but I'm unsure how to do it, I tried running the lua program and browsing there, dropping the xfuscator file on top of the program etc but nothing has given any result.How should I do it?
Open a command line (e.g. under windows, that's cmd). Go into the directory where you have your local copy of XFuscator. Make sure lua is on your PATH. Type
lua XFuscator.lua -h
This should show the help message, which will describe the next steps.

f# file not running

I am a noob when it comes to f#, I am a phd student in Maths and I am trying to run the following:
http://blogs.msdn.com/b/dsyme/archive/2011/03/10/slides-and-demo-scripts-for-sigcse.aspx
Under the zip file Demos/TwitterFeed/.....
I am trying to run the files in the TwitterFeed. I have never used f# and when I try to run it under visualstudio shell I get errors. Could anybody please help me.
Thanks,
Mohit
In twitterstream.fsx, change the #load directive for twitterpassword.fs to the following:
#load "TwitterPassword.fs"
This should fix it.

Resources