Questions

How can I use threading in Python?

I am trying to understand threading in Python. I've looked at the documentation and examples, but quite frankly, many examples are overly sophisticated and I'm having trouble understanding them. How d...

How to compare arrays in JavaScript?

I'd like to compare two arrays... ideally, efficiently. Nothing fancy, just `true` if they are identical, and `false` if not. Not surprisingly, the comparison operator doesn't seem to work. ``` var a...

4 Oct at 22:21

Sort (order) data frame rows by multiple columns

I want to sort a data frame by multiple columns. For example, with the data frame below I would like to sort by column 'z' (descending) then by column 'b' (ascending): ``` dd <- data.frame(b = factor(...

7 Dec at 17:45

Ignoring directories in Git repositories on Windows

How can I ignore directories or folders in Git using msysgit on Windows?

14 Nov at 13:48

Hidden Features of C#?

This came to my mind after I learned the following from [this question](http://www.stackoverflow.com/questions/8941/generic-type-checking): ``` where T : struct ``` We, C# developers, all know the ...

25 Sep at 20:53

How do I remove the passphrase for the SSH key without having to create a new key?

I set a passphrase when creating a new SSH key on my laptop. But, as I realise now, this is quite painful when you are trying to commit ([Git](http://en.wikipedia.org/wiki/Git_%28software%29) and [SVN...

26 Jul at 05:0

Changing git commit message after push (given that no one pulled from remote)

I have made a git commit and subsequent push. I would like to change the commit message. If I understand correctly, this is not advisable because someone might have pulled from the remote repository b...

17 Jun at 08:14

Check synchronously if file/directory exists in Node.js

How can I synchronously check, using , if a file or directory exists?

20 Jan at 14:4

How does the "this" keyword work, and when should it be used?

I am looking to find a clear explanation of what the "this" keyword does, and how to use it correctly. It seems to behave strangely, and I don't fully understand why. How does `this` work and when sho...

17 Jun at 11:53

What is the difference between a field and a property?

In C#, what makes a field different from a property, and when should a field be used instead of a property?

20 Jul at 04:54

Find when a file was deleted in Git

I have a Git repository with n commits. I have a file that I need, and that used to be in the repository, and that I suddenly look for and think "Oh! Where'd that file go?" Is there a (series of) Gi...

12 Jan at 23:10

How can I "add existing frameworks" in Xcode 4?

I can't find the good old "Add existing frameworks" option. How do I do this? We're talking about Xcode 4 DP2 (in the context of iPhone development, as far as it matters...).

11 Sep at 15:33

What is the difference between match_parent and fill_parent?

I'm a little confused about two XML properties: `match_parent` and `fill_parent`. It seems that both are the same. Is there any difference between them?

12 Mar at 13:35

How to redirect output to a file and stdout

In bash, calling `foo` would display any output from that command on the stdout. Calling `foo > output` would redirect any output from that command to the file specified (in this case 'output'). Is ...

19 Jun at 07:56

Turning off auto indent when pasting text into vim

I am making the effort to learn Vim. When I paste code into my document from the clipboard, I get extra spaces at the start of each new line: ``` line line line ``` I know you can turn off a...

Path.Combine for URLs?

[Path.Combine](https://msdn.microsoft.com/en-us/library/system.io.path.combine%28v=vs.110%29.aspx) is handy, but is there a similar function in the .NET framework for [URLs](http://en.wikipedia.org/wi...

3 Feb at 15:1

How can I center an absolutely positioned element in a div?

I want to place a `div` (with `position:absolute;`) element in the center of the window. But I'm having problems doing so, because the . I tried the following CSS code, but it needs to be adjusted bec...

25 Jul at 09:50

Check if element exists in jQuery

How do I check if an element exists if the element is created by `.append()` method? `$('elemId').length` doesn't work for me.

8 Sep at 16:10

Using group by on multiple columns

I understand the point of `GROUP BY x`. But how does `GROUP BY x, y` work, and what does it mean?

22 Jul at 14:47

Activity restart on rotation Android

In my Android application, when I rotate the device (slide out the keyboard) then my `Activity` is restarted (`onCreate` is called). Now, this is probably how it's supposed to be, but I do a lot of in...

12 Nov at 15:1

Custom HTTP headers : naming conventions

Several of our users have asked us to include data relative to their account in the of requests we send them, or even responses they get from our API. What is the general convention to add custom HTT...

24 Aug at 22:5

How to force Docker for a clean build of an image

I have build a Docker image from a Docker file using the below command. ``` $ docker build -t u12_core -f u12_core . ``` When I am trying to rebuild it with the same command, it's using the build c...

16 Dec at 09:3

Can I concatenate multiple MySQL rows into one field?

Using `MySQL`, I can do something like: ``` SELECT hobbies FROM peoples_hobbies WHERE person_id = 5; ``` ``` shopping fishing coding ``` but instead I just want 1 row, 1 col: ``` shopping, f...

19 Apr at 11:22

Virtual member call in a constructor

I'm getting a warning from ReSharper about a call to a virtual member from my objects constructor. Why would this be something not to do?

Is there a way to get the source code from an APK file?

The hard drive on my laptop just crashed and I lost all the source code for an app that I have been working on for the past two months. All I have is the APK file that is stored in my email from when ...