Monthly Archives: May 2017

Java Fundamentals and Machine Learning Summary and Resources

1.Inheritance can be defined as the process where one class acquires the properties (methods and fields) of another. With the use of inheritance the information is made manageable in a hierarchical order.   2. If a class inherits a method … Continue reading

Posted in CS Research&Application, Uncategorized | Tagged , , | Leave a comment

Programming Reflection May 17

1. Array is easy to index specific element with index, it’s easier to calculate the difference between different elements than linked list. 2. LeetCode Trap Rain Water problem: iterate left and right elements for each element in the input array, … Continue reading

Posted in CS Research&Application, Intern&Job, IT, Uncategorized | Tagged , , , | Leave a comment

Node.js Production Tips

1. Slug Routes: slug-routes gives you the ability to use some unique piece of data to represent your records in URLs other than the ID. https://github.com/felixkiss/slug-routes   2. Docker Docker is an open platform for developers and sysadmins to build, … Continue reading

Posted in CS Research&Application, Uncategorized | Tagged , , | Leave a comment

Keystone.js Framework Tips (2)

1. Test in keystone.js I use Mocha as test runner to tell what passes and fails, and Chai for assertion or should libraries to run specific tests. https://groups.google.com/forum/?nomobile=true#!topic/keystonejs/AvpvUpHNTn0 http://stackoverflow.com/questions/22231078/how-do-i-unit-test-keystonejs-models https://gist.github.com/rtgibbons/e18d8066680a0350fe41 https://github.com/webteckie/keystonejs-stub 2. create a gap between tr (table rows) http://stackoverflow.com/questions/1264187/css-how-do-i-create-a-gap-between-rows-in-a-tableContinue reading

Posted in Uncategorized | Leave a comment

8 HTML, CSS, JavaScript and MongoDB Tips

1. A million dollar css mistake Sometimes when you click or highlight a part of text, and it will blink or change to a different color. The reason why it happens is there are multiple style definition (color for active … Continue reading

Posted in CS Research&Application, Uncategorized | Tagged , , , , | Leave a comment

Node.js Middleware Packages — sitemap, robots.txt

1. keystone-express-sitemap Dynamic sitemap generation for applications built on KeystoneJS 2. express-robots Express middleware for generating a robots.txt or responding with an existing file. Donate $5 to me for a coffee with PayPal and read more professional and interesting technical blog articles. Feel free to visit … Continue reading

Posted in CS Research&Application, Uncategorized | Tagged , , , , | Leave a comment

iOS (Objective C) Development Tips

1. UITableView vs UICollectionView scroll to bottom UITableView scroll to bottom (2nd answer) http://stackoverflow.com/questions/5112346/uitableview-scroll-to-bottom-on-reload UICollectionView scroll to bottom http://stackoverflow.com/questions/16955783/is-there-a-way-to-automatically-scroll-to-the-bottom-of-a-uicollectionview 2. UILabel dynamic height http://stackoverflow.com/questions/446405/adjust-uilabel-height-depending-on-the-text http://stackoverflow.com/questions/27374612/how-do-i-calculate-the-uilabel-height-dynamically http://stackoverflow.com/questions/31228831/how-to-give-dynamic-height-to-uilabel-programatically-in-swift collection view height dynamic width Auto Layout width <= threshold (217) and leading/trailing constraint … Continue reading

Posted in Uncategorized, iOS | Tagged , , , , | Leave a comment