Skip to main content

All Questions

Tagged with
43 votes
13 answers
11k views

How does Python's handling of line-breaks differ from JavaScript's automatic semicolons?

Javascript has a feature called Automatic Semicolon Insertion where basically if the parser encounters an invalid token, and the last token before that was a line break, then the parser will insert a ...
Einar Egilsson's user avatar
3 votes
4 answers
1k views

Do all dynamically typed languages not support function overloading?

I have noticed that JavaScript and PHP and Python do not support function overloading. Do all dynamically typed languages not support function overloading? If the answer is yes, then why is that?
William's user avatar
  • 65
10 votes
4 answers
1k views

What is the historical basis of using Javascript in web programming?

I come from a scientific biology background where we also use Python a lot. Now that I've begun to start with Web development, I've consistently found myself wondering just why it is that JavaScript ...
rd108's user avatar
  • 211
3 votes
2 answers
404 views

What is the rationale for making certain methods for data types static?

In C#, for instance, there are static methods for telling if a string is null or empty, finding an element in an array, clearing an array, etc. However there's an instance method for replacing ...
Ace's user avatar
  • 617
-2 votes
2 answers
2k views

Should I use Flask w/ Javascript OR a Javascript UI that calls a Flask / Connexion API?

I recently wrote a data management tool in Python & SQLAlchemy. Now, I need to put a web UI on it. While I want to start small, there is some need for interactivity, like drag and drop in tables, ...
Ben's user avatar
  • 115
10 votes
11 answers
16k views

Do I have to learn html and javascript to create web applications? [closed]

I am an experienced Java programmer, and I want to create a complex web application requiring dynamic pages, drawings, etc (take SO as an example). Do I have to learn javascript/html in order to ...
vainolo's user avatar
  • 1,341
0 votes
1 answer
118 views

How encrypting website data works

If i wanted to encrypt a password on my website before its sent to the server, would i have to encrypt the password in javascript on the frontend for it to be hidden over the interent or could it be ...
TheAdmin's user avatar
18 votes
5 answers
11k views

Algorithm for flattening overlapping ranges

I am looking for a nice way of flattening (splitting) a list of potentially-overlapping numeric ranges. The problem is very similar to that of this question: Fastest way to split overlapping date ...
Jollywatt's user avatar
  • 321
17 votes
7 answers
9k views

Would Python be too slow for client-side use in Browsers?

I've heard the statement that Python would be too slow to be of any use in browsers. I reckon Javascript is only superior in this aspect because of companies like Google who need it fast (and made it ...
Profpatsch's user avatar
24 votes
3 answers
4k views

Why do so many languages treat numbers starting with 0 as octal?

I've read Where are octals useful? and it seems like octals are something that were once upon a time useful. Many languages treat numbers preceding with a 0 as octal, so the literal 010 is actually 8....
Manishearth's user avatar
-3 votes
2 answers
1k views

How can I calculate the radius of an arc given by a series of points

Given a series of points, I need to assert that the plotted points form an arc (with a certain level of confidence), and I need to approximate the radius of the arc. For example, the following points ...
Yanick Rochon's user avatar
-2 votes
1 answer
988 views

How to make code runnable on open source code editors like Ace Editor?

For my computer science uni project I'm required to build a web application with an integrated code editor. I believe I can just integrate open source editors like Ace Editor. However, I feel ...
Sonjeet Paul's user avatar
2 votes
1 answer
4k views

Best practices for calling multiple APIs and manipulating data before showing it to user?

I am building a web application that makes use of multiple API's (Google Maps, Weather APIs, and more). I am using Python + Flask on the backend, and Javascript (probably with React, I have not ...
Brian C's user avatar
  • 147
7 votes
2 answers
4k views

Every function is a closure?

Wikipedia says, that closure - is a function, which has an access to variables, declared outside of the function. There is even an example: function startAt(x) function incrementBy(y) ...
ozahorulia's user avatar
0 votes
2 answers
257 views

Code style to keep track of nested objects and data types?

In untyped languages (Python, Javascript specifically) find myself making a lot of bugs / wasting a lot of time because I forget what's in the objects I'm passing around. For example, I forget things ...
Jess's user avatar
  • 173

15 30 50 per page