See what the Stackoverflow community is most excited about today.
Date: 2017-10-13
-
In Ruby on Rails, what's the difference between DateTime, Timestamp, Time and Date?
tags: ruby-on-rails, datetime, date, time, timestamp
354 votes, 2 answers and 83530 views
\r\n In my experience, getting dates/times right when programming is always fraught with danger and difficulity. \n\nRuby and Rails have always eluded me on this one, if only due to the overwhelming number ...\r\n
-
Why does this code, written backwards, print “Hello World!”
tags:
214 votes, 4 answers and 11465 views
\r\n Here is some code that I found on the Internet:\n\nclass M{public static void main(String[]a){System.out.print(new char[]\n{'H','e','l','l','o',' ','W','o','r','l','d','!'});}} \r\nThis code prints ...\r\n
-
Pros/cons of using redux-saga with ES6 generators vs redux-thunk with ES2017 async/await
tags: javascript, reactjs, redux, redux-thunk, redux-saga
272 votes, 5 answers and 57525 views
\r\n There is a lot of talk about the latest kid in redux town right now, yelouafi/redux-saga. It uses generator functions for listening to/dispatching actions.\n\nBefore I wrap my head around it, I would ...\r\n
-
How do you perform wireless debugging in Xcode 9 with iOS 11, Apple TV 4K, etc?
tags: ios, xcode, debugging, ios11, xcode9
186 votes, 11 answers and 34756 views
\r\n Wireless debugging was recently added as a feature in Xcode 9, iOS 11, and tvOS 11. Apple TV 4K doesn't have a USB port, so it requires wireless debugging. How do you perform this wireless debugging ...\r\n
-
Angular 2 HTTP GET with TypeScript error http.get(…).map is not a function in [null]
tags: typescript, angular, rxjs
198 votes, 5 answers and 112709 views
\r\n I have a problem with HTTP in Angular 2. \n\nI just want to GET a JSON list and show it in the view. \n\nService class\n\nimport {Injectable} from "angular2/core";\nimport {Hall} from "./hall";\nimport {Http} ...\r\n
-
How to deal with SettingWithCopyWarning in Pandas?
tags: python, parsing, pandas, dataframe
181 votes, 6 answers and 160859 views
\r\n Background\n\nI just upgraded my Pandas from 0.11 to 0.13.0rc1. Now, the application is popping out many new warnings. One of them like this:\n\nE:\FinReporter\FM_EXT.py:449: SettingWithCopyWarning: A ...\r\n
-
tags: typescript
237 votes, 7 answers and 178153 views
\r\n I'm trying to create get and set method for a property:\n\nprivate _name: string;\n\nName() {\n get:\n {\n return this._name;\n }\n set:\n {\n this._name = ???;\n }\n}\r\nWhat's the ...\r\n
-
How to read csv into record array in numpy?
tags: python, numpy, scipy, genfromtxt
225 votes, 7 answers and 288607 views
\r\n I wonder if there is a direct way to import the contents of a csv file into a record array, much in the way that R's read.table(), read.delim(), and read.csv() family imports data to R's data frame? \n\n...\r\n
-
The use of Swift 3 @objc inference in Swift 4 mode is deprecated?
tags: swift, swift4, xcode9-beta
200 votes, 6 answers and 24999 views
\r\n Briefly, while using Xcode 9 Beta, I have run into the following warning:\r\n The use of Swift 3 @objc inference in Swift 4 mode is deprecated. Please address deprecated @objc inference warnings, test ...\r\n
-
add one row in a pandas.DataFrame
tags: python, pandas
321 votes, 15 answers and 375945 views
\r\n I understand that pandas is designed to load fully populated DataFrame but I need to create an empty DataFrame then add rows, one by one.\nWhat is the best way to do this ?\n\nI successfully created an ...\r\n