Discuss Scratch
- Discussion Forums
- » Advanced Topics
- » js or python
- Maximouse
- Scratcher
1000+ posts
js or python
It's actually more strict (but of course it depends on what you mean by “strict”).Python is more beginner friendly and less strict. i use js
which one is better tho
- Greg8128
- Scratcher
500+ posts
js or python
Showing errors is an objectively good thing.Python doesnt punish you for tiny mistakes, while other languages doIt's actually more strict (but of course it depends on what you mean by “strict”).Python is more beginner friendly and less strict. i use js
which one is better tho
*By punish I mean showing errors
- Foruminasnew2scratch
- New to Scratch
37 posts
js or python
I've only really learned python, I'm not much into coding.
No. I am not @Steve0Greatness
(note - I hate the fact that as a New Scratcher you have to wait 120 minutes)
- gosoccerboy5
- Scratcher
1000+ posts
js or python
javascript, who will silently fail if you try to do something stupid like multiply strings: *nervous sweating*Showing errors is an objectively good thing. Python doesnt punish you for tiny mistakes, while other languages do
*By punish I mean showing errors
- -Rex-
- Scratcher
500+ posts
js or python
Python has classes and JavaScript doesn’t, so I’d say that Python is probably better designed, but I’d still rather use JavaScript because it’s easier to use in the browser and has much better general-purpose performance (Python has PyPy but it’s still slower than V8). I have seen some TypeScript but have no experience in it. I have recently experimented with C++ and Emscripten and it seems nice but somewhat overkill.
I’d still rather use C++, C# or Java over either Python or JavaScript.
I’d still rather use C++, C# or Java over either Python or JavaScript.
- gosoccerboy5
- Scratcher
1000+ posts
js or python
Python has classes and JavaScript doesn’tecmascript 2015 allows you to use ‘classes’ in your code that are mainly syntactical sugar
- Rendangbike2
- Scratcher
1000+ posts
js or python
That's not JS.Python has classes and JavaScript doesn’tecmascript 2015 allows you to use ‘classes’ in your code that are mainly syntactical sugar
- gdpr5b78aa4361827f5c2a08d700
- Scratcher
1000+ posts
js or python
JavaScript has classes Python has classes and JavaScript doesn’t, so I’d say that Python is probably better designed, but I’d still rather use JavaScript because it’s easier to use in the browser and has much better general-purpose performance (Python has PyPy but it’s still slower than V8). I have seen some TypeScript but have no experience in it. I have recently experimented with C++ and Emscripten and it seems nice but somewhat overkill.
I’d still rather use C++, C# or Java over either Python or JavaScript.
- ElsieBreeze
- Scratcher
100+ posts
js or python
ECMAScript is the specification that the JavaScript Language follows.That's not JS.Python has classes and JavaScript doesn’tecmascript 2015 allows you to use ‘classes’ in your code that are mainly syntactical sugar
- Sheep_maker
- Scratcher
1000+ posts
js or python
Python has classes and JavaScript doesn’t,Scratch says otherwise!
Apparently in Python 2, there were some quirks with their classes resulting in a split between old- and new-style classes; presumably Python 3 took the opportunity to break backwards compatibility by only using the new-style classes
- Sheep_maker This is a kumquat-free signature. :P
This is my signature. It appears below all my posts. Discuss it on my profile, not the forums. Here's how to make your own.
.postsignature { overflow: auto; } .scratchblocks { overflow-x: auto; overflow-y: hidden; }
- gosoccerboy5
- Scratcher
1000+ posts
js or python
lolThat's not JS.Python has classes and JavaScript doesn’tecmascript 2015 allows you to use ‘classes’ in your code that are mainly syntactical sugar
- Raihan142857
- Scratcher
1000+ posts
js or python
Python has classes and JavaScript doesn’t, so I’d say that Python is probably better designed, but I’d still rather use JavaScript because it’s easier to use in the browser and has much better general-purpose performance (Python has PyPy but it’s still slower than V8). I have seen some TypeScript but have no experience in it. I have recently experimented with C++ and Emscripten and it seems nice but somewhat overkill.Javascript has classes
I’d still rather use C++, C# or Java over either Python or JavaScript.
I use scratch.
GF: I'll dump you. BF: hex dump or binary dump?
- Rendangbike2
- Scratcher
1000+ posts
js or python
Is there a way to make a game with pure JS? No HTML allowed, just JS. Luckily, in Python; we can do that.
- Maximouse
- Scratcher
1000+ posts
js or python
Yes, use something like node-canvas. Is there a way to make a game with pure JS? No HTML allowed, just JS. Luckily, in Python; we can do that.
- Raihan142857
- Scratcher
1000+ posts
js or python
like my extremely readable snake gameYes, use something like node-canvas. Is there a way to make a game with pure JS? No HTML allowed, just JS. Luckily, in Python; we can do that.
(Z=(m=document).body).append(c=m.createElement`canvas`);F=(r=c.getContext`2d`).fillRect.bind(r);c.width=500,c.height=N=300;c.style="position:fixed;top:0;z-index:1e9";(R=_=>{s=[250],a=N,b=150,t=[b],x=1,y=0})();setInterval(`r[f="fillStyle"]='#000';F(0,0,500,N);r[f]='red';F(a,b,n=10,n);r[f]='#0F0';for(j in s)F(s[j],t[j],n,n);S=s[0]+n*x,T=t[0]-n*y;o(S,T)?R():s.unshift(S),t.unshift(T);if(o(a,b))for(;o(a,b);)a=n*(new(M=Date)%50),b=n*(new M%30);else s.pop(),t.pop();(S+n)%510&&(T+n)%310||R()`,100);m.onkeydown=e=>{k=e.keyCode-37,k^32||Z.removeChild(c);k<5&k>-1&&(x=k%2?0:x?x:k-1,y=k%2?y?y:2-k:0)};o=(A,B)=>s.some((i,j)=>i==A&t[j]==B)
I use scratch.
GF: I'll dump you. BF: hex dump or binary dump?
- gosoccerboy5
- Scratcher
1000+ posts
js or python
rock paper scissors Is there a way to make a game with pure JS? No HTML allowed, just JS. Luckily, in Python; we can do that.
- Rendangbike2
- Scratcher
1000+ posts
js or python
Make Platformer.rock paper scissors Is there a way to make a game with pure JS? No HTML allowed, just JS. Luckily, in Python; we can do that.
- Sheep_maker
- Scratcher
1000+ posts
js or python
That doesn't use node-canvas. It requires HTML since you're using documentlike my extremely readable snake gameYes, use something like node-canvas. Is there a way to make a game with pure JS? No HTML allowed, just JS. Luckily, in Python; we can do that.(Z=(m=document).body).append(c=m.createElement`canvas`);F=(r=c.getContext`2d`).fillRect.bind(r);c.width=500,c.height=N=300;c.style="position:fixed;top:0;z-index:1e9";(R=_=>{s=[250],a=N,b=150,t=[b],x=1,y=0})();setInterval(`r[f="fillStyle"]='#000';F(0,0,500,N);r[f]='red';F(a,b,n=10,n);r[f]='#0F0';for(j in s)F(s[j],t[j],n,n);S=s[0]+n*x,T=t[0]-n*y;o(S,T)?R():s.unshift(S),t.unshift(T);if(o(a,b))for(;o(a,b);)a=n*(new(M=Date)%50),b=n*(new M%30);else s.pop(),t.pop();(S+n)%510&&(T+n)%310||R()`,100);m.onkeydown=e=>{k=e.keyCode-37,k^32||Z.removeChild(c);k<5&k>-1&&(x=k%2?0:x?x:k-1,y=k%2?y?y:2-k:0)};o=(A,B)=>s.some((i,j)=>i==A&t[j]==B)
- Sheep_maker This is a kumquat-free signature. :P
This is my signature. It appears below all my posts. Discuss it on my profile, not the forums. Here's how to make your own.
.postsignature { overflow: auto; } .scratchblocks { overflow-x: auto; overflow-y: hidden; }