How to convert list to string
How can I convert a list to a string using Python?
What are the most common Python docstring formats?
I have seen a few different styles of writing docstrings in Python, what are the most popular styles?
- Modified
- 27 Nov at 23:49
How to force browsers to reload cached CSS and JS files?
I have noticed that some browsers (in particular, Firefox and [Opera](https://en.wikipedia.org/wiki/Opera_%28web_browser%29)) are very zealous in using cached copies of and files, even between brows...
- Modified
- 6 Sep at 22:3
How do I retrieve an HTML element's actual width and height?
Suppose that I have a `<div>` that I wish to center in the browser's display (viewport). To do so, I need to calculate the width and height of the `<div>` element. What should I use? Please include ...
- Modified
- 19 Aug at 20:46
How to iterate over arguments in a Bash script
I have a complex command that I'd like to make a shell/bash script of. I can write it in terms of `$1` easily: ``` foo $1 args -o $1.ext ``` I want to be able to pass multiple input names to the s...
- Modified
- 10 Jan at 02:16
Calculate distance between two latitude-longitude points? (Haversine formula)
How do I calculate the distance between two points specified by latitude and longitude? For clarification, I'd like the distance in kilometers; the points use the WGS84 system and I'd like to underst...
- Modified
- 11 Sep at 17:15
Return multiple values in JavaScript?
I am trying to return two values in . Is this possible? ``` var newCodes = function() { var dCodes = fg.codecsCodes.rs; var dCodes2 = fg.codecsCodes2.rs; return dCodes, dCodes2; }; ``...
- Modified
- 17 Apr at 18:9
List all environment variables from the command line
Is it possible to list environment variables from a Windows' command prompt? Something equivalent to PowerShell's `gci env:` (or `ls env:` or `dir env:`).
- Modified
- 27 Apr at 12:11
Show git diff on file in staging area
Is there a way I can see the changes that were made to a `file` after I have done `git add file`? That is, when I do: ``` git add file git diff file ``` no diff is shown. I guess there's a way to...
Why use Redux over Facebook Flux?
I've read [this answer](https://stackoverflow.com/questions/32021763/what-could-be-the-downsides-of-using-redux-instead-of-flux), [reducing boilerplate](http://redux.js.org/docs/recipes/ReducingBoiler...
- Modified
- 5 Jul at 03:59
What is your most productive shortcut with Vim?
I've heard a lot about [Vim](http://www.vim.org/), both pros and cons. It really seems you should be (as a developer) faster with Vim than with any other editor. I'm using Vim to do some basic stuff a...
How to convert UTF-8 byte[] to string
I have a `byte[]` array that is loaded from a file that I happen to known contains [UTF-8](http://en.wikipedia.org/wiki/UTF-8). In some debugging code, I need to convert it to a string. Is there a one...
- Modified
- 6 Aug at 16:10
No 'Access-Control-Allow-Origin' header is present on the requested resource—when trying to get data from a REST API
I'm trying to fetch some data from the REST API of HP Alm. It works pretty well with a small curl script—I get my data. Now doing that with JavaScript, fetch and ES6 (more or less) seems to be a bigge...
- Modified
- 14 Aug at 12:48
How do I use $scope.$watch and $scope.$apply in AngularJS?
I don't understand how to use `$scope.$watch` and `$scope.$apply`. The official documentation isn't helpful. What I don't understand specifically: - - - I tried [this tutorial](http://css.dzone.co...
- Modified
- 7 Jan at 15:1
What is the difference between public, private, and protected?
When and why should I use `public`, `private`, and `protected` functions and variables inside a class? What is the difference between them? Examples: ``` // Public public $variable; public function ...
What is the difference between ++i and i++?
In C, what is the difference between using `++i` and `i++`, and which should be used in the incrementation block of a `for` loop?
- Modified
- 15 Mar at 10:32
How can I make Bootstrap columns all the same height?
I'm using Bootstrap. How can I make three columns all the same height? Here is a screenshot of the problem. I would like the blue and red columns to be the same height as the yellow column. ![Three...
- Modified
- 23 Jun at 21:36
How can I change the name of an iOS app in Xcode?
I began an iPhone project the other day with a silly development code name, and now I want to change the name of the project since it's nearly finished. How can I do this?
What is the difference between g++ and gcc?
What is the difference between g++ and gcc? Which one of them should be used for general c++ development?
What is the difference between String.slice and String.substring?
Does anyone know what the difference is between these two methods? ``` String.prototype.slice String.prototype.substring ```
- Modified
- 17 Apr at 18:26
How do I get the current absolute URL in Ruby on Rails?
How can I get the current URL in my Ruby on Rails view? The `request.request_uri` only returns the URL.
- Modified
- 29 Mar at 19:33
How do you auto format code in Visual Studio?
I know Visual Studio can auto format to make my methods and loops indented properly, but I cannot find the setting.
- Modified
- 8 Oct at 14:9
Find the min/max element of an array in JavaScript
How can I easily obtain the min or max element of a JavaScript array? Example pseudocode: ``` let array = [100, 0, 50] array.min() //=> 0 array.max() //=> 100 ```
- Modified
- 18 Feb at 11:40
What is the difference between old style and new style classes in Python?
What is the difference between old style and new style classes in Python? When should I use one or the other?
- Modified
- 29 Oct at 14:2