Oct. 18, 2016
Cannot believe that best talent people are the professors in top universities. I am doubting that IT industry could not provide the position for the talent.
Here is how Julia conducts her research "what to work on, what to read, and what to follow". She is leaving weekends for HackerRank contest, therefore, the life style change leads to her learning style change as well.
Detail see the blog:
The blog is how to work on the performance of competition. Focus on basics.
http://juliachencoding.blogspot.ca/2016/10/hackerrank-openbracket-codesprint.html
To warm up the topic, think about how Julia works hard and sacrifice her weekend to strength her ability to perform in the world wide contest on HackerRank (Just basically go over the profile and see who is sharing ...), she did over 4 hours (one hour after each contest at least) to try to find the best people to be her mentor over months, now she found one.
Julia works on the research how to learn, what to learn as a software programmer, over 6 years in the city of Vancouver. She just learn how other side of party, how to teach? Best talent people on algorithms choose to teach.
https://www.hackerrank.com/rpeng
OpenBracket CodeSprint • 7/ 2450 participants
->
http://www.cc.gatech.edu/~rpeng/
->
http://www.cc.gatech.edu/~rpeng/teachingstatement.pdf
Julia's favorite new teaching approach:
"My teaching draws upon my research in data structures, algorithms, graph theory, optimization, statistics, geometry, numerical analysis, and parallel computing. Connecting these topics and enabling students to effectively utilize key ideas from them is one of my main teaching goals. These connections are often best motivated by key problems on the boundaries of these areas. Solving such problems usually requires adapting various tools from these areas, leading to a deeper understanding of both the tools and the problems. For example, instead of presenting sorting algorithms and balanced search trees separately, I prefer to discuss applications that integrate them such as geometric plane sweep algorithms. I believe this problem oriented exposition is helpful for using the tools later on, as well as for moving towards open-ended exploration in an area."
->
"I also seek opportunities to interact with students in a wider range of academic activities. Having participated in outreach activities such as math and programming camps while in high school, I regularly volunteered for them after graduating. Since 2006, I’ve been involved with the USA Computing Olympiad, whose annual online competitions attract around two thousand participants from high schools worldwide."
USA Computing Olympiad Team
http://usaco.org/index.php?page=staff
From January 2015, she started to practice leetcode questions; she trains herself to stay focus, develops "muscle" memory when she practices those questions one by one. 2015年初, Julia开始参与做Leetcode, 开通自己第一个博客. 刷Leet code的题目, 她看了很多的代码, 每个人那学一点, 也开通Github, 发表自己的代码, 尝试写自己的一些体会. She learns from her favorite sports – tennis, 10,000 serves practice builds up good memory for a great serve. Just keep going. Hard work beats talent when talent fails to work hard.
Tuesday, October 18, 2016
Sunday, October 16, 2016
Leetcode solutions following Java Code Style
Oct. 16, 2016
Plan to spend 2 hours to read the Java code styles:
1.
https://google.github.io/styleguide/javaguide.html
2.
https://github.com/douglasleer/LeetCode-Java-Solutions-Code-Sample
Plan to spend 2 hours to read the Java code styles:
1.
https://google.github.io/styleguide/javaguide.html
2.
https://github.com/douglasleer/LeetCode-Java-Solutions-Code-Sample
HackerRank contest pressure and countermeasures
Oct. 16, 2016
Just a quick summary, music, dance, sports, with the art to mix them by Adias commercial, Julia found her way to release the contest stress by watching the video:
Garbiñe Muguruza: Episode 3: Keeping Happy
Here are more details:
Julia spent Saturday on Oct. 16, 2016 to work on one algorithm, she finally made full score 40 of 40 after 10 hours struggle - keep scoring 0, until she could not believe that she won two bronze medal of HackerRank contest.
As a reminder, she always remembers that tennis sayings, every one knows how to play tennis, but mental is most important part.
She went back to read the problem statement of the algorithm, and noticed that she should take advantage of expeditures range 0, 200, and used bucket sort. She made it full score after 1 hour coding.
Here is the problem statement.
Second day, she felt pressure and tried to go back to work after she waked up, even it was 5:00am; but then, she decided to relax with some entertainment.
Here are the videos:
1. How to celebrate win?
2. Garbiñe Muguruza
Garbiñe Muguruza: Episode 1: On Court
Garbiñe Muguruza: Episode 2: Off Court
Garbiñe Muguruza: Episode 3: Keeping Happy
(tennis can be very demanding, but leaving everything behind, just having fun. )
4. #CreateYourMark: Hit the court with the stars of Roland Garros
5. Ana, Caroline, Andrea and Tomas Berdych Create Noise in Melbourne
Actionable items:
Julia scored the HackerRank contest Open Bracket 60 out of 250, worked on two algorithms first day of contest; she likes to push herself to full speed starting from 9:25am, score 2 more algorithms if possible.
Now, 10/16/2016, 9:25 am, she ranks 401/ 2001.
Play to win!
Just a quick summary, music, dance, sports, with the art to mix them by Adias commercial, Julia found her way to release the contest stress by watching the video:
Garbiñe Muguruza: Episode 3: Keeping Happy
Here are more details:
Julia spent Saturday on Oct. 16, 2016 to work on one algorithm, she finally made full score 40 of 40 after 10 hours struggle - keep scoring 0, until she could not believe that she won two bronze medal of HackerRank contest.
As a reminder, she always remembers that tennis sayings, every one knows how to play tennis, but mental is most important part.
She went back to read the problem statement of the algorithm, and noticed that she should take advantage of expeditures range 0, 200, and used bucket sort. She made it full score after 1 hour coding.
Here is the problem statement.
Second day, she felt pressure and tried to go back to work after she waked up, even it was 5:00am; but then, she decided to relax with some entertainment.
Here are the videos:
1. How to celebrate win?
2. Garbiñe Muguruza
Garbiñe Muguruza: Episode 1: On Court
Garbiñe Muguruza: Episode 2: Off Court
Garbiñe Muguruza: Episode 3: Keeping Happy
(tennis can be very demanding, but leaving everything behind, just having fun. )
4. #CreateYourMark: Hit the court with the stars of Roland Garros
5. Ana, Caroline, Andrea and Tomas Berdych Create Noise in Melbourne
Actionable items:
Julia scored the HackerRank contest Open Bracket 60 out of 250, worked on two algorithms first day of contest; she likes to push herself to full speed starting from 9:25am, score 2 more algorithms if possible.
Now, 10/16/2016, 9:25 am, she ranks 401/ 2001.
Play to win!
China Open, Tennis, Beijing - A big learning experience
Sept. 29 - Oct. 15 China vacation
Sept. 30 - Oct. 3, 2016
As a tennis sports amateur player, Julia spent 4 days to stay in Beijing, first 4 days of vacation, spent time with hundreds of others,
enjoyed watching WTA, ATP players practice, double/ single matches.
She learned by watching, she talked to other fans, and she sat and watched hours long matches.
It is a different experience, when she gets so close to tennis pros and observes how they prepare for matches.
For example, she observed how ex-world top 1 player Martina Hingis practiced close to 1 hour; Julia just could not believe that Martina Hingis was on the court and Julia was sitting next to court, although she watched her play through youtube.com a lot of times.
It is a different experience, when she gets so close to tennis pros and observes how they prepare for matches.
For example, she observed how ex-world top 1 player Martina Hingis practiced close to 1 hour; Julia just could not believe that Martina Hingis was on the court and Julia was sitting next to court, although she watched her play through youtube.com a lot of times.
China open is a big event of tennis, 5th biggest event; since Vancouver no longer hosts Holyburn tennis event, Julia has to travel to China and catch more events in Beijing, Shanghai.
Julia likes to have some tennis players as her role models, like Mirtina Hingis .
Julia likes to have some tennis players as her role models, like Mirtina Hingis .
She will come back to document more on her experience through China open 2015.
HackerRank - OpenBracket CodeSprint
Oct. 15, 2016
The Saturday and Sunday (Oct. 15 - Oct. 16) are reserved for HackerRank OpenBracket CodeSprint.
Came back from the vacation trip (Sept. 29, 2016 - Oct. 14, 2016) from China on Oct. 14, 2016, Julia spent 2 days to rest at home to overcome jet lag, and also she was busy with algorithm problem solving.
Read blogs:
Julia values the contest - as a training, and also she likes to check leaderboad, and see what she can learn from others.
Leaderboard of OpenBracker CodeSprint:
Here is the chain she worked on:
https://www.hackerrank.com/rpeng
OpenBracket CodeSprint • 7/ 2450 participants
->
http://www.cc.gatech.edu/~rpeng/
->
http://www.cc.gatech.edu/~rpeng/teachingstatement.pdf
Julia's favorite new teaching approach:
"My teaching draws upon my research in data structures, algorithms, graph theory, optimization, statistics, geometry, numerical analysis, and parallel computing. Connecting these topics and enabling students to effectively utilize key ideas from them is one of my main teaching goals. These connections are often best motivated by key problems on the boundaries of these areas. Solving such problems usually requires adapting various tools from these areas, leading to a deeper understanding of both the tools and the problems. For example, instead of presenting sorting algorithms and balanced search trees separately, I prefer to discuss applications that integrate them such as geometric plane sweep algorithms. I believe this problem oriented exposition is helpful for using the tools later on, as well as for moving towards open-ended exploration in an area."
->
"I also seek opportunities to interact with students in a wider range of academic activities. Having participated in outreach activities such as math and programming camps while in high school, I regularly volunteered for them after graduating. Since 2006, I’ve been involved with the USA Computing Olympiad, whose annual online competitions attract around two thousand participants from high schools worldwide."
USA Computing Olympiad Team
http://usaco.org/index.php?page=staff
->
http://www.cc.gatech.edu/~rpeng/CV.pdf
"ACM-ICPC International Collegiate Programming Contest 2008 1 st at the 2007 East Central North American regionals, 9th at the 2008 ACM-ICPC World Finals."
Programming Competitions Occasionally volunteers as practice partner / punching bag for active contestants. User id rpeng on competitive programming websites, TopCoder rating 2509, Codeforces rating 2242.
-> That is a hunting game Julia likes to do:
http://www.cc.gatech.edu/~rpeng/CV.pdf
|
\ /
Plan to spend 10 hours to work on the course first. (10/18/2016)
http://www.andrew.cmu.edu/course/15-295-archive/f12/
-> Know one more judge a time - called: Timus Online Judge
http://acm.timus.ru/help.aspx?topic=judge
->
http://www.cs.cmu.edu/~sleator/
->
http://contest.cs.cmu.edu/295/f16/
10 - 20 minutes to go over once - (10/18/2016), segment tree is Julia's favorite to learn.
A.
http://contest.cs.cmu.edu/295/tutorials/seg_tree.cc
B. Min cost flow
http://contest.cs.cmu.edu/295/tutorials/min-cost-flow.txt
C. Union find
http://contest.cs.cmu.edu/295/tutorials/union-find.txt
To join the 15-295 codeforces group, first create your codeforces account. Then go to this 15-295 Codeforces Group page. On this page you should see a list of the contests created for this course.
http://codeforces.com/group/KIrM1Owd8u/contests
Competition programming courses:
http://contest.cs.cmu.edu/295/
There are a number of excellent tutorials on the algorithms and techniques needed to solve these kinds of contest programs on Topcoder's Data Science Tutorials web site.
https://www.topcoder.com/community/data-science/data-science-tutorials/
The Saturday and Sunday (Oct. 15 - Oct. 16) are reserved for HackerRank OpenBracket CodeSprint.
Came back from the vacation trip (Sept. 29, 2016 - Oct. 14, 2016) from China on Oct. 14, 2016, Julia spent 2 days to rest at home to overcome jet lag, and also she was busy with algorithm problem solving.
Read blogs:
Julia values the contest - as a training, and also she likes to check leaderboad, and see what she can learn from others.
Leaderboard of OpenBracker CodeSprint:
Here is the chain she worked on:
https://www.hackerrank.com/rpeng
OpenBracket CodeSprint • 7/ 2450 participants
->
http://www.cc.gatech.edu/~rpeng/
->
http://www.cc.gatech.edu/~rpeng/teachingstatement.pdf
Julia's favorite new teaching approach:
"My teaching draws upon my research in data structures, algorithms, graph theory, optimization, statistics, geometry, numerical analysis, and parallel computing. Connecting these topics and enabling students to effectively utilize key ideas from them is one of my main teaching goals. These connections are often best motivated by key problems on the boundaries of these areas. Solving such problems usually requires adapting various tools from these areas, leading to a deeper understanding of both the tools and the problems. For example, instead of presenting sorting algorithms and balanced search trees separately, I prefer to discuss applications that integrate them such as geometric plane sweep algorithms. I believe this problem oriented exposition is helpful for using the tools later on, as well as for moving towards open-ended exploration in an area."
->
"I also seek opportunities to interact with students in a wider range of academic activities. Having participated in outreach activities such as math and programming camps while in high school, I regularly volunteered for them after graduating. Since 2006, I’ve been involved with the USA Computing Olympiad, whose annual online competitions attract around two thousand participants from high schools worldwide."
USA Computing Olympiad Team
http://usaco.org/index.php?page=staff
->
http://www.cc.gatech.edu/~rpeng/CV.pdf
"ACM-ICPC International Collegiate Programming Contest 2008 1 st at the 2007 East Central North American regionals, 9th at the 2008 ACM-ICPC World Finals."
Programming Competitions Occasionally volunteers as practice partner / punching bag for active contestants. User id rpeng on competitive programming websites, TopCoder rating 2509, Codeforces rating 2242.
-> That is a hunting game Julia likes to do:
http://www.cc.gatech.edu/~rpeng/CV.pdf
|
\ /
Plan to spend 10 hours to work on the course first. (10/18/2016)
http://www.andrew.cmu.edu/course/15-295-archive/f12/
-> Know one more judge a time - called: Timus Online Judge
http://acm.timus.ru/help.aspx?topic=judge
->
http://www.cs.cmu.edu/~sleator/
->
http://contest.cs.cmu.edu/295/f16/
10 - 20 minutes to go over once - (10/18/2016), segment tree is Julia's favorite to learn.
A.
http://contest.cs.cmu.edu/295/tutorials/seg_tree.cc
B. Min cost flow
http://contest.cs.cmu.edu/295/tutorials/min-cost-flow.txt
C. Union find
http://contest.cs.cmu.edu/295/tutorials/union-find.txt
To join the 15-295 codeforces group, first create your codeforces account. Then go to this 15-295 Codeforces Group page. On this page you should see a list of the contests created for this course.
http://codeforces.com/group/KIrM1Owd8u/contests
Competition programming courses:
http://contest.cs.cmu.edu/295/
There are a number of excellent tutorials on the algorithms and techniques needed to solve these kinds of contest programs on Topcoder's Data Science Tutorials web site.
https://www.topcoder.com/community/data-science/data-science-tutorials/
Saturday, October 15, 2016
ACM cheat sheet - 3 hours drill
Sept. 29 - Oct. 15 China vacation
Oct. 12, 2016
Julia spent 3 hours to read the ACM cheat sheet book on Oct. 12, 2016 while taking the train from the city of Yichun to Shanghai.
How to prepare ACM contest?
https://github.com/soulmachine/acm-cheat-sheet
What she did is to memorize catalog.
She enjoyed the reading very much. She will write down some notes here.
Oct. 12, 2016
Julia spent 3 hours to read the ACM cheat sheet book on Oct. 12, 2016 while taking the train from the city of Yichun to Shanghai.
How to prepare ACM contest?
https://github.com/soulmachine/acm-cheat-sheet
What she did is to memorize catalog.
She enjoyed the reading very much. She will write down some notes here.
programmer competency matrix
Sept. 29 - Oct. 15 China vacation
Oct. 10, 2016
Julia was on vacation and experienced the jet lag, waked up early in the morning around 3:30am; and then, she received a notification of linkedin connection she sent out in June 2016, and then, she went through the connection's linkedin profile, and the she started to read the article:
http://sijinjoseph.com/programmer-competency-matrix/
Julia noticed that she made 2 new linkedin connection through her vacation, one from Google.com, one from Amazon.com.
Here are 2 new connections through Linkedin:
1. https://www.linkedin.com/in/tanbernard
Value the coaching I got from the Amazon talent through Amazon tech event in 2016, "It does not matter how old you are, it matters if you are very competitive on programming".
2. https://www.linkedin.com/in/minminhan
Actionable Items:
Write down 3 things in the matrix - need to work on
Oct. 10, 2016
Julia was on vacation and experienced the jet lag, waked up early in the morning around 3:30am; and then, she received a notification of linkedin connection she sent out in June 2016, and then, she went through the connection's linkedin profile, and the she started to read the article:
http://sijinjoseph.com/programmer-competency-matrix/
Julia noticed that she made 2 new linkedin connection through her vacation, one from Google.com, one from Amazon.com.
Here are 2 new connections through Linkedin:
1. https://www.linkedin.com/in/tanbernard
Value the coaching I got from the Amazon talent through Amazon tech event in 2016, "It does not matter how old you are, it matters if you are very competitive on programming".
2. https://www.linkedin.com/in/minminhan
Actionable Items:
Write down 3 things in the matrix - need to work on
A small research - From HackerRank to weChat public account
Sept. 29 - Oct. 15 China vacation
Oct. 5, 2016
Julia likes to spend time to get to know top talent people in software industry, for example, she just went through HackerRank leader board, and then, checked one by one if she has 1 or 2 hours. She found one, and then, the talent also has a public wechat account, with great influence in China.
http://www.weidu8.net/author/mindwind_essay
Oct. 5, 2016
Julia likes to spend time to get to know top talent people in software industry, for example, she just went through HackerRank leader board, and then, checked one by one if she has 1 or 2 hours. She found one, and then, the talent also has a public wechat account, with great influence in China.
http://www.weidu8.net/author/mindwind_essay
Small research on wechat public account
Oct. 15, 2016
Sept. 29 - Oct. 15 China vacation
Julia started to spend time to read blogs, from a public account of wechat ID: angelaTalk, a programmer, a computer science PH.D. of Rise university, Airbnb programmer.
http://chuansong.me/n/538061341827
https://www.linkedin.com/in/angelazhu1
Excellent blogs about code review, sillicon valley, performance review and her personal experience about family and career choices.
Sept. 29 - Oct. 15 China vacation
Julia started to spend time to read blogs, from a public account of wechat ID: angelaTalk, a programmer, a computer science PH.D. of Rise university, Airbnb programmer.
http://chuansong.me/n/538061341827
https://www.linkedin.com/in/angelazhu1
Excellent blogs about code review, sillicon valley, performance review and her personal experience about family and career choices.
Born to be a warrior - Sharapova interview
Oct. 8, 2016
Spent Sept. 29 - Oct. 15 on the vacation from Vancouver to Beijing, Yichun, and then Shanghai. Experienced a lot of things as a professional software programmer.
Need to write down one by one. First one is about WTA grand slam champion Sharapove.
Born to be a warrior - How Sharapova handles interview? About doping? About her determination to back to WTA tour?
https://www.youtube.com/watch?v=rWaBVelzaFk
https://www.youtube.com/watch?v=pyeAbGKx8JA
Sharapova Limbers Up | Australian Open 2015
https://www.youtube.com/watch?v=qv__59QPf-4
Spent one hour on Sunday morning - Oct. 23, 2016 - 11:00 am - 12:00am
Learn how good the talk is -
https://www.youtube.com/watch?v=x9dKia7kC8E
Spent Sept. 29 - Oct. 15 on the vacation from Vancouver to Beijing, Yichun, and then Shanghai. Experienced a lot of things as a professional software programmer.
Need to write down one by one. First one is about WTA grand slam champion Sharapove.
Born to be a warrior - How Sharapova handles interview? About doping? About her determination to back to WTA tour?
https://www.youtube.com/watch?v=rWaBVelzaFk
https://www.youtube.com/watch?v=pyeAbGKx8JA
Sharapova Limbers Up | Australian Open 2015
https://www.youtube.com/watch?v=qv__59QPf-4
Spent one hour on Sunday morning - Oct. 23, 2016 - 11:00 am - 12:00am
Learn how good the talk is -
https://www.youtube.com/watch?v=x9dKia7kC8E
Monday, September 26, 2016
HackerEarth: algorithm tutorial and problems
Sept. 26, 2016
Julia has some difficulty to handle medium, advanced, hard and difficult algorithm on HackerRank contest world code sprint, so she is actively seeking ways to improve.
Try this one - HackerEarth, at least read each algorithm and find typical problem sets; if need, she can quickly jump into the code. She tries to shorten the time from learning the algorithm to working out an algorithm in 8 hours. So she can compete in the contest.
It is hard to compete in the contest right now, to cover her weakness, she has to dedicate a lot of time for a medium level algorithm. She has to give up weekend sports activities, has to focus on the contest whole weekend, nonstop.
One algorithm a time. One contest a time.
It does not matter how hard Julia has to work on contest, at the end of day - more than 8 hours work, she has to be able to come out a solution for a medium algorithm on HackerRank contest.
The contest problem solving is very similar to the work environment; 48 hours is much better than 24 hours. Julia likes the challenges, she just likes to compete, also she thinks that it is very healthy to compete, so she can improve performance in short time. She could not learn these from the work.
HackerRank is very strict on scoring, therefore, Julia is pushed so hard to bring out her best talent, relentless trial and errors, patiently through 8 hours a time.
Here is the website:
https://www.hackerearth.com/practice/algorithms/dynamic-programming/introduction-to-dynamic-programming-1/tutorial/
Recommended by
https://goo.gl/K3iYRY
Julia has some difficulty to handle medium, advanced, hard and difficult algorithm on HackerRank contest world code sprint, so she is actively seeking ways to improve.
Try this one - HackerEarth, at least read each algorithm and find typical problem sets; if need, she can quickly jump into the code. She tries to shorten the time from learning the algorithm to working out an algorithm in 8 hours. So she can compete in the contest.
It is hard to compete in the contest right now, to cover her weakness, she has to dedicate a lot of time for a medium level algorithm. She has to give up weekend sports activities, has to focus on the contest whole weekend, nonstop.
One algorithm a time. One contest a time.
It does not matter how hard Julia has to work on contest, at the end of day - more than 8 hours work, she has to be able to come out a solution for a medium algorithm on HackerRank contest.
The contest problem solving is very similar to the work environment; 48 hours is much better than 24 hours. Julia likes the challenges, she just likes to compete, also she thinks that it is very healthy to compete, so she can improve performance in short time. She could not learn these from the work.
HackerRank is very strict on scoring, therefore, Julia is pushed so hard to bring out her best talent, relentless trial and errors, patiently through 8 hours a time.
Here is the website:
https://www.hackerearth.com/practice/algorithms/dynamic-programming/introduction-to-dynamic-programming-1/tutorial/
Recommended by
https://goo.gl/K3iYRY
HackerRank - World code sprint #7 - summary
Sept. 26, 2016
Good news! A bronze medal! Top 25%.
It was a busy weekend, Julia spent over 10 hours a day on algorithm problem solving, scored 67.81, ranked 737/ 5269 at 12:27am, 9/26/2016, still 7 hours left. Usually China is day time next 7 hours, the rank will go down more.
The experience was so different from her practice on Leetcode algorithm. She learned some new skills through long hours struggling. Most of things are about how to scale large data, timeout issue, out-of-memory. She found out the joy of programming.
Some facts to set high standards, try to get into top 12% of contest, despite lack of preparation:
It is a 48 hours contest. Saturday and Sunday two days.
1. She only did one mile driving on last Sunday to spend 30 minutes to do grocery shopping, and two days to stay at home, worked on the algorithms.
2. On Saturday, spent 8+ hours to work on an algorithm using interval (Leetcode 56: Intervals), worked on timeout, design issues, space issues - out-of-memory. Score 20 out of 20 after 8 hours work.
3. On Sunday, spent 8+ hours to score 20 out of 40 - DP problem.
Still timeout, DP solution is not fast enough.
Spent first 2 hours to work on dynamic programming test cases, figured out the recurrence formula.
Actionable items:
1. Spend some time to read those blogs about contests, figure out what to learn from. (plan to read 2 - 3 hours)
http://blog.csdn.net/philipsweng
How other people review their contest? (Ranking: 14/5000, score 345/ 400)
http://blog.csdn.net/philipsweng/article/details/51730709
2. read blog 2+ hours, find ideas to work on
https://www.quora.com/profile/Bohdan-Pryshchenko
HackerRank profile:
https://www.hackerrank.com/I_love_Tanya
3. another one:
https://www.quora.com/profile/Joshua-Pan-1
https://goo.gl/K3iYRY
4. Read some algorithms: (instead of Googling, use the website for reference - catch up - reading - plan to spend first 3 hours on this)
https://www.hackerearth.com/practice/algorithms/dynamic-programming/bit-masking/tutorial/
Will document more later.
5. 9/28/2015
Some analysis - Julia only can score 15% (70/ 400) compared to best talent people in the world, if she works damn hard. Time wise, she could not solve difficult level algorithm yet, no data. 15% wise, She only score 70/400 in code sprint, but best one scores 400 in less than 10 hours.
But through the contest, she knows that she can close the gap and measure the progress in every month, every contest. Set up 5 stages - 15%, 25%, 30%, 40%, 50%, and relax and enjoy problem solving day by day.
Good news! A bronze medal! Top 25%.
It was a busy weekend, Julia spent over 10 hours a day on algorithm problem solving, scored 67.81, ranked 737/ 5269 at 12:27am, 9/26/2016, still 7 hours left. Usually China is day time next 7 hours, the rank will go down more.
The experience was so different from her practice on Leetcode algorithm. She learned some new skills through long hours struggling. Most of things are about how to scale large data, timeout issue, out-of-memory. She found out the joy of programming.
Some facts to set high standards, try to get into top 12% of contest, despite lack of preparation:
It is a 48 hours contest. Saturday and Sunday two days.
1. She only did one mile driving on last Sunday to spend 30 minutes to do grocery shopping, and two days to stay at home, worked on the algorithms.
2. On Saturday, spent 8+ hours to work on an algorithm using interval (Leetcode 56: Intervals), worked on timeout, design issues, space issues - out-of-memory. Score 20 out of 20 after 8 hours work.
3. On Sunday, spent 8+ hours to score 20 out of 40 - DP problem.
Still timeout, DP solution is not fast enough.
Spent first 2 hours to work on dynamic programming test cases, figured out the recurrence formula.
Actionable items:
1. Spend some time to read those blogs about contests, figure out what to learn from. (plan to read 2 - 3 hours)
http://blog.csdn.net/philipsweng
How other people review their contest? (Ranking: 14/5000, score 345/ 400)
http://blog.csdn.net/philipsweng/article/details/51730709
2. read blog 2+ hours, find ideas to work on
https://www.quora.com/profile/Bohdan-Pryshchenko
HackerRank profile:
https://www.hackerrank.com/I_love_Tanya
3. another one:
https://www.quora.com/profile/Joshua-Pan-1
https://goo.gl/K3iYRY
4. Read some algorithms: (instead of Googling, use the website for reference - catch up - reading - plan to spend first 3 hours on this)
https://www.hackerearth.com/practice/algorithms/dynamic-programming/bit-masking/tutorial/
Another favorite of mine is — #2 HackerEarth (includes tutorials and separated into categories/sorted easiest to hardest): Algorithms Tutorials & Practice Problems
- A note about this: I really enjoyed HackEarth’s previous practice section (it was a lot better formatted). If anyone can get this to HackerEarth executives, that would be a great piece of advice for them.
Will document more later.
5. 9/28/2015
Some analysis - Julia only can score 15% (70/ 400) compared to best talent people in the world, if she works damn hard. Time wise, she could not solve difficult level algorithm yet, no data. 15% wise, She only score 70/400 in code sprint, but best one scores 400 in less than 10 hours.
But through the contest, she knows that she can close the gap and measure the progress in every month, every contest. Set up 5 stages - 15%, 25%, 30%, 40%, 50%, and relax and enjoy problem solving day by day.
HackerRank - world code sprint #7 - Gridland Metro
Sept. 26, 2016
Problem statement
Julia spent over 8+ hours to work on this algorithm. She learned so many things, and most of important, she liked to train herself - strong determination, after 8+ hours, near 10pm, she was so surprised that she made full score 25 out of 25, because she started to adopt new way of thinking. She looked up her blog, and then find the idea:
Avoid overcomplicate code
from the blog
So, she starts to practice advice she learned through reading, and then she enjoyed the great success on this problem solving.
Will come back later to write more. More than 8 hours work, a lot of things to review.
Come back on Sept. 27, 2016
1. submission 1: pass test case 1, score 0
4 hours work, score 0; but the algorithm is working.
2. pass 3 of 30 test cases, score 1.67/ 25, 2nd C# practice.
3. score 1.67/ 25, 3rd C# practice.
4. score 4.17, pass 6 of 30 test cases, small progress, 4th practice.
5. try to pass any test case from test 7 - 30, failed once. 5th practice.
6. failed second try to pass test cases from 7 - 30, still score 4.17. 6th practice.
7. break through test case 7 -30, still failed, still score 4.17, 7th practice.
8. last try to break through test cases from 7 - 30, failed. still score 4.17
One thing for sure is that Julia has high standard now, she understands that it is important to continue to give up code, even write a new one, if code smells slightly.
Even if the code passes all test cases, but she likes to present code with good style.
Through the last 3 tries, she found several issues:
1. The bug she tried to fix is in different abstraction level, but stay in the same function. see line 218 - 222 of source code.
Code review under pressure was so exciting; Julia remembered the saying after 6+ hours continuous work - "avoid complicated code"; the function (line from 197 - 257 of source code ) is too complicated, doing too many things.
9. Score 25 of 25, more than 8 hours work - using LINQ, Lambda function, source code.
The loop has the fatal weakness dealing with large, unknown data set, it leads to a unresolvable bug; In other words, collection
"sortedRows" can be filtered out more. Need to work on distinct row number.
line 212: foreach (int rowNo in distinctRows) (section 9), source code.
March 4, 2017
Julia reviewed the algorithm, and she was so surprised that she had to spend near 2 hours to relearn the algorithm, the code written in the contest had so many issues. She was happy to understand better how to write readable code after 3 months experience on codereview.stackexchange.com.
She wrote the C# solution and also asked the question. The blog is here and code review is here.
Problem statement
Julia spent over 8+ hours to work on this algorithm. She learned so many things, and most of important, she liked to train herself - strong determination, after 8+ hours, near 10pm, she was so surprised that she made full score 25 out of 25, because she started to adopt new way of thinking. She looked up her blog, and then find the idea:
Avoid overcomplicate code
from the blog
So, she starts to practice advice she learned through reading, and then she enjoyed the great success on this problem solving.
Will come back later to write more. More than 8 hours work, a lot of things to review.
Come back on Sept. 27, 2016
1. submission 1: pass test case 1, score 0
4 hours work, score 0; but the algorithm is working.
2. pass 3 of 30 test cases, score 1.67/ 25, 2nd C# practice.
3. score 1.67/ 25, 3rd C# practice.
4. score 4.17, pass 6 of 30 test cases, small progress, 4th practice.
5. try to pass any test case from test 7 - 30, failed once. 5th practice.
6. failed second try to pass test cases from 7 - 30, still score 4.17. 6th practice.
7. break through test case 7 -30, still failed, still score 4.17, 7th practice.
8. last try to break through test cases from 7 - 30, failed. still score 4.17
One thing for sure is that Julia has high standard now, she understands that it is important to continue to give up code, even write a new one, if code smells slightly.
Even if the code passes all test cases, but she likes to present code with good style.
Through the last 3 tries, she found several issues:
1. The bug she tried to fix is in different abstraction level, but stay in the same function. see line 218 - 222 of source code.
Code review under pressure was so exciting; Julia remembered the saying after 6+ hours continuous work - "avoid complicated code"; the function (line from 197 - 257 of source code ) is too complicated, doing too many things.
9. Score 25 of 25, more than 8 hours work - using LINQ, Lambda function, source code.
Highlights of change: break through test case 7 - 30
line 216: foreach (int row in sortedRows) (section 8), source code.The loop has the fatal weakness dealing with large, unknown data set, it leads to a unresolvable bug; In other words, collection
"sortedRows" can be filtered out more. Need to work on distinct row number.
line 212: foreach (int rowNo in distinctRows) (section 9), source code.
Review after 6 month
March 4, 2017
Julia reviewed the algorithm, and she was so surprised that she had to spend near 2 hours to relearn the algorithm, the code written in the contest had so many issues. She was happy to understand better how to write readable code after 3 months experience on codereview.stackexchange.com.
She wrote the C# solution and also asked the question. The blog is here and code review is here.
HackerRank - World CodeSprint #7 - Summing Pieces
Sept. 26, 2016
Problem statement
Spent over 8+ hours to work on the algorithm, really enjoyed the algorithm. It is different experience, with strong determination to make some points, took more than 2+ hours to figure out the dynamic programming formula - should call recurrence formula. Started from scoring 4.00 points, moved up to 19.00 out of 40.00.
What a learning experience, totally different from projects at work/ university. Will document the detail experience, what Julia should learn after she reviews/ analyzes the practice.
Will come back later.
Step 1:
submission 1, pass first 3 test cases - score 4.14/ 40
Step 2:
score 11 out of 40 - step 2 / 4 (4, 11, 14, 19 out of 40)
use line 78, line 98, extra string array to help debugging the code, make it short to fix the issues in the code. But, this extra code has
to be removed later to gain 2 points.
Step 3:step 3 / 4 ( 4, 11, 14, 19 out of 40)
Step 4:
score 13.9
step 4: score 19 out of 40
March 3, 2017
Review the algorithm, write a complete solution, and then post a question on codereview.stackexchange.com.
And also do some research how to win a silver medal, Julia was very close to a silver medal on this world codesprint #7,
Problem statement
Julia is a warrior in the contest - fearless, she feels at home
Spent over 8+ hours to work on the algorithm, really enjoyed the algorithm. It is different experience, with strong determination to make some points, took more than 2+ hours to figure out the dynamic programming formula - should call recurrence formula. Started from scoring 4.00 points, moved up to 19.00 out of 40.00.
What a learning experience, totally different from projects at work/ university. Will document the detail experience, what Julia should learn after she reviews/ analyzes the practice.
Will come back later.
Progression to 19/ 40
Step 1:
submission 1, pass first 3 test cases - score 4.14/ 40
Step 2:
score 11 out of 40 - step 2 / 4 (4, 11, 14, 19 out of 40)
use line 78, line 98, extra string array to help debugging the code, make it short to fix the issues in the code. But, this extra code has
to be removed later to gain 2 points.
Step 3:step 3 / 4 ( 4, 11, 14, 19 out of 40)
Step 4:
score 13.9
step 4: score 19 out of 40
Six months later - follow up review
March 3, 2017
Review the algorithm, write a complete solution, and then post a question on codereview.stackexchange.com.
And also do some research how to win a silver medal, Julia was very close to a silver medal on this world codesprint #7,
HackerRank - World code sprint #7 - Similar Strings
Sept. 26, 2016
Work on scalability issue related to string algorithm:
https://www.hackerrank.com/contests/world-codesprint-7/challenges/similar-strings
Will find 30 minutes to one hour, write some code and then start to learn through the practice.
Will come back later.
Comment:
Julia spent more 8 hours to score 10 out of 40 on a dynamic programming algorithm Summing Pieces (medium level), actually she should spend 1 - 2 hours to work on this string algorithm.
Work on scalability issue related to string algorithm:
https://www.hackerrank.com/contests/world-codesprint-7/challenges/similar-strings
Will find 30 minutes to one hour, write some code and then start to learn through the practice.
Will come back later.
Comment:
Julia spent more 8 hours to score 10 out of 40 on a dynamic programming algorithm Summing Pieces (medium level), actually she should spend 1 - 2 hours to work on this string algorithm.
Sunday, September 25, 2016
Range Minimum Query
Sept. 25, 2016
Work on HackerRank world code sprint #7, algorithm: (Hard, score 60)
Inverse RMQ -
https://www.hackerrank.com/contests/world-codesprint-7/challenges/inverse-rmq
Julia's idea about the problem solving: (12 hours to end the contest, 10:00pm Sunday evening)
Try to study 1 - 2 hour segment tree, and see if there is a miracle!
Study Range Minimum Query:
http://www.geeksforgeeks.org/segment-tree-set-1-sum-of-given-range/
http://www.geeksforgeeks.org/segment-tree-set-1-range-minimum-query/
https://www.quora.com/How-to-count-inversions-using-Segment-Tree-of-a-given-array
http://letuskode.blogspot.ca/2013/01/segtrees.html
Read some Chinese blogs about segment tree:
1. http://www.cnblogs.com/tanky_woo/archive/2010/09/25/1834523.html
2. http://www.cnitblog.com/cockerel/archive/2006/09/13/16806.html
Work on HackerRank world code sprint #7, algorithm: (Hard, score 60)
Inverse RMQ -
https://www.hackerrank.com/contests/world-codesprint-7/challenges/inverse-rmq
Julia's idea about the problem solving: (12 hours to end the contest, 10:00pm Sunday evening)
Try to study 1 - 2 hour segment tree, and see if there is a miracle!
Study Range Minimum Query:
http://www.geeksforgeeks.org/segment-tree-set-1-sum-of-given-range/
http://www.geeksforgeeks.org/segment-tree-set-1-range-minimum-query/
https://www.quora.com/How-to-count-inversions-using-Segment-Tree-of-a-given-array
http://letuskode.blogspot.ca/2013/01/segtrees.html
Read some Chinese blogs about segment tree:
1. http://www.cnblogs.com/tanky_woo/archive/2010/09/25/1834523.html
2. http://www.cnitblog.com/cockerel/archive/2006/09/13/16806.html
Saturday, September 24, 2016
Vancouver woman tech - 2016 event in downtown Vancouver, Microsoft office
Sept. 24, 2016
On Sept. 22, 2016, Julia enjoyed the trip to Microsoft new office in the city of Vancouver downtown, she enjoyed everything; so, she likes to write down the journey, reminds her that how hard people are working to make her life easy, happy, rich-learning experience day-by-day. When she has a little moment, she can come back here to get the spirit back, work hard again, to learn from 2016 WTA ranking No.1 Angelique, 3 Grand slams finals, 2 champions.
Here are some twitter links for the detail of talk:
1. https://twitter.com/jianminchen/status/779453061991321600
2. https://twitter.com/jianminchen/status/779451604332228608
3. https://twitter.com/jianminchen/status/779451415743766528
And here are some personal experience of food, great view of downtown, and Microsoft office - art and inspiration things:
It is close to Canadian Thanksgiving holiday, Oct. 10, 2016. But kind of nervous, try to rush in more projects to get more rewarding to finish 2016 strong.
On Sept. 22, 2016, Julia enjoyed the trip to Microsoft new office in the city of Vancouver downtown, she enjoyed everything; so, she likes to write down the journey, reminds her that how hard people are working to make her life easy, happy, rich-learning experience day-by-day. When she has a little moment, she can come back here to get the spirit back, work hard again, to learn from 2016 WTA ranking No.1 Angelique, 3 Grand slams finals, 2 champions.
Here are some twitter links for the detail of talk:
1. https://twitter.com/jianminchen/status/779453061991321600
2. https://twitter.com/jianminchen/status/779451604332228608
3. https://twitter.com/jianminchen/status/779451415743766528
And here are some personal experience of food, great view of downtown, and Microsoft office - art and inspiration things:
It is close to Canadian Thanksgiving holiday, Oct. 10, 2016. But kind of nervous, try to rush in more projects to get more rewarding to finish 2016 strong.
Web usability research
Sept. 24, 2016
Spent 2+ hours to do some research on web usability. At the end of study, Julia found the joy to watch TED talk from Margaret Gould Stewart, she knew that her study leaded to great experience of learning, expand her knowledge as a software programmer.
First, let us have some highlights of study, then, have the detail of study.
Two TED talks:
1. Three lessons for designing for the whole world
2. How giant websites design for you and a billion others too?
kind of messy, will be organized better very soon.
1. From code smells study, move to next topic: web usability & user experience. (2+ hours study)
Borrow some ideas from website usability & user experience - Julia, you need to read 60 pages - page by page first.
Study Website Usability & User Experience (UX) Definition
(60 pages - plan to read 1- 2 hours, understand the concepts first)
http://blog.usabilla.com/the-abc-of-usability/
http://blog.usabilla.com/6-ted-talks-every-ux-professional-should-watch/
Spent 2+ hours to do some research on web usability. At the end of study, Julia found the joy to watch TED talk from Margaret Gould Stewart, she knew that her study leaded to great experience of learning, expand her knowledge as a software programmer.
First, let us have some highlights of study, then, have the detail of study.
Highlights
Two TED talks:
1. Three lessons for designing for the whole world
2. How giant websites design for you and a billion others too?
More details of study
kind of messy, will be organized better very soon.
1. From code smells study, move to next topic: web usability & user experience. (2+ hours study)
Borrow some ideas from website usability & user experience - Julia, you need to read 60 pages - page by page first.
Study Website Usability & User Experience (UX) Definition
(60 pages - plan to read 1- 2 hours, understand the concepts first)
http://blog.usabilla.com/the-abc-of-usability/
http://blog.usabilla.com/6-ted-talks-every-ux-professional-should-watch/
How Code smells research leads to the website Usability research? User experience research?
It is an interesting journey, study clean code book -> code smells -> web usability -> user experience (UX)
2. Coding training -> More study on user experience, code readability, build good ritual before coding.
http://blog.usabilla.com/5-effective-ways-for-usability-testing-to-play-nice-with-agile/
More Google search:
Margaret Gould Stewart facebook
https://www.ted.com/speakers/margaret_stewart
http://ideas.ted.com/want-to-dig-into-design-facebooks-ux-master-offers-some-must-reads/
http://blog.ted.com/three-lessons-for-designing-for-the-whole-world-margaret-gould-stewart-at-ted2014/
What’s really hard at designing at scale, is that it requires a bizarre combination of two things, audacity and humility.
It is an interesting journey, study clean code book -> code smells -> web usability -> user experience (UX)
2. Coding training -> More study on user experience, code readability, build good ritual before coding.
More reading
http://blog.usabilla.com/5-effective-ways-for-usability-testing-to-play-nice-with-agile/
More Google search:
Margaret Gould Stewart facebook
https://www.ted.com/speakers/margaret_stewart
http://ideas.ted.com/want-to-dig-into-design-facebooks-ux-master-offers-some-must-reads/
http://blog.ted.com/three-lessons-for-designing-for-the-whole-world-margaret-gould-stewart-at-ted2014/
Julia's favorite notes:
What’s really hard at designing at scale, is that it requires a bizarre combination of two things, audacity and humility.
Wednesday, September 21, 2016
Blog reading - Computer Science Top Talent
Sept. 21, 2016
Plan to spend 2+ hours to read the blogs -
http://jeanyang.com/
http://jxyzabc.blogspot.ca/
Julia's favorite blogs:
http://jxyzabc.blogspot.ca/search/label/advice
http://jxyzabc.blogspot.ca/2011/08/clothes-shopping-on-grad-student-budget.html
http://jxyzabc.blogspot.ca/2010/09/art-of-taking-breaks.html
Plan to spend 2+ hours to read the blogs -
http://jeanyang.com/
http://jxyzabc.blogspot.ca/
Julia's favorite blogs:
http://jxyzabc.blogspot.ca/search/label/advice
http://jxyzabc.blogspot.ca/2011/08/clothes-shopping-on-grad-student-budget.html
http://jxyzabc.blogspot.ca/2010/09/art-of-taking-breaks.html
video:
Tuesday, September 20, 2016
A small research - web technology new school to catch up
Sept. 20, 2016
Julia is preparing the list of things to learn through pluralsight.com about new school web technologies. Her favorite project is to write a single web page application using Angular JS, bootstrap, MVC, entity framwork; and she likes to see people use her single page application one day, since small population uses her apps daily very often, for them, like Gmail app, a most popular single page application.
So, she did some study about the teaching statement from the computer professor (From teaching statement: http://pgbovine.net/apps/faculty-2015/pguo-teaching-statement_2015.pdf ):
I emphasize to students that the specifics of which programming languages, libraries, frameworks, and deployment services are in vogue at the moment change at a rapid pace, and that these new technologies are easy to pick up on-the-job once they have developed strong foundations. In my dynamic programming languages course, I take students on a deep dive of the Python interpreter source code to show them how a modern dynamic language is implemented from the ground up in C. Again, my goal is not to train students to become specialized Python developers, but rather to illustrate general principles that hold for any dynamic language such as JavaScript, Ruby, Scheme, and future languages that have not even been invented yet. I have noticed that students take a course more seriously when the instructor is firmly committed to rigor and high standards.
From teaching statement:
http://pgbovine.net/apps/faculty-2015/pguo-teaching-statement_2015.pdf
Here is the list of web tool she likes to catch up:
Julia is preparing the list of things to learn through pluralsight.com about new school web technologies. Her favorite project is to write a single web page application using Angular JS, bootstrap, MVC, entity framwork; and she likes to see people use her single page application one day, since small population uses her apps daily very often, for them, like Gmail app, a most popular single page application.
So, she did some study about the teaching statement from the computer professor (From teaching statement: http://pgbovine.net/apps/faculty-2015/pguo-teaching-statement_2015.pdf ):
I emphasize to students that the specifics of which programming languages, libraries, frameworks, and deployment services are in vogue at the moment change at a rapid pace, and that these new technologies are easy to pick up on-the-job once they have developed strong foundations. In my dynamic programming languages course, I take students on a deep dive of the Python interpreter source code to show them how a modern dynamic language is implemented from the ground up in C. Again, my goal is not to train students to become specialized Python developers, but rather to illustrate general principles that hold for any dynamic language such as JavaScript, Ruby, Scheme, and future languages that have not even been invented yet. I have noticed that students take a course more seriously when the instructor is firmly committed to rigor and high standards.
From teaching statement:
http://pgbovine.net/apps/faculty-2015/pguo-teaching-statement_2015.pdf
Here is the list of web tool she likes to catch up:
The latest web tools and technologies, including:
- JavaScript
- EcmaScript 6/7 (via Babel)
- HTML 5
- CSS 3
- JSON
- React
- Flux/Redux
- D3
- Webpack
- REST
- Node.js
Blog to read:
https://www.cs.cmu.edu/~jyang2/press.html
https://people.eecs.berkeley.edu/~bjoern/app/hartmann-teaching.pdf
From my background, I draw three core pedagogical beliefs: to foster undergraduate research through apprenticeship; encourage experiential learning through studio-based, project-centric courses; and emphasize writing as a core academic skill.
http://icc.ucdavis.edu/mpp/workshop-archives.htm
https://people.eecs.berkeley.edu/~bjoern/app/hartmann-teaching.pdf
From my background, I draw three core pedagogical beliefs: to foster undergraduate research through apprenticeship; encourage experiential learning through studio-based, project-centric courses; and emphasize writing as a core academic skill.
http://icc.ucdavis.edu/mpp/workshop-archives.htm
Code smells - Book chapter reading
Sept. 20, 2016
Read clean code book - Chapter 17 - Smells and Heuristics
Julia's notes:
Comments
Environments
General
Java
Names
Tests
Comments:
C1: Inappropriate Information
C2: Obsolete Comment
C3: Rudundant Comment
C4: Poorly Written Comment
C5: Commented-Out Code
Environment:
E1: Build Requires More Than One Step
E2: Tests Require More Than One Step
Functions:
F1: Too Many Arguments
F2: Output Arguments
F3: Flag Arguments
F4: Dead Function
General - (hightlights to help memorize - red color, Julia produced the code with smells...)
G1: Multiple Languages in One Source File
G2: Obvious Behavior Is Unimplemented
G3: Incorrect Behavior at the Boundaries
G4: Overridden Safeties
G5: Duplication
G6: Code at Wrong Level of Abstraction
G7: Base Classes Depending on Their Derivatives
G8: Too Much Information
G9: Dead Code
G10: Vertical Separation
G11: Inconsistency - the principle of least surprise
G12: Clutter
G13: Artificial Coupling - lazy and careless of placement of a variable, constant or function
G14: Feature Envy -
G15: Selector Arguments
Great blog about clean code: CMU - top 4 computer science - a professor
http://jxyzabc.blogspot.ca/2012/12/treat-yo-self-clean-up-your-code.html
"During the course of grad school, my relationship with my code has become increasingly important. Clean, modular, and well-documented code (with tests!) is not only less likely to have bugs but will be useful for longer. Clean code provides a solid foundation for you and potentially other researchers. Modular code makes it easier to reuse parts of your code. Also, knowing exactly what your code does just feels good."
Editorial notes:
1. Clean, modular, and well-documented code (with tests!)
Julia, let us hold high standards as a software programmer -
Review common code smells before you write code for a project.
2. Work on blog writing, and see if you can write good blogs as
http://jxyzabc.blogspot.ca
3. work on the blog:
http://jxyzabc.blogspot.ca/search/label/academic%20advice
study writing - write down things to learn from the above article
4. Borrow some ideas from website usability & user experience - Julia, you need to read 60 pages - page by page first.
Study Website Usability & User Experience (UX) Definition
(60 pages - plan to read 1- 2 hours, understand the concepts first)
http://blog.usabilla.com/the-abc-of-usability/
http://blog.usabilla.com/6-ted-talks-every-ux-professional-should-watch/
Read clean code book - Chapter 17 - Smells and Heuristics
Julia's notes:
Comments
Environments
General
Java
Names
Tests
Comments:
C1: Inappropriate Information
C2: Obsolete Comment
C3: Rudundant Comment
C4: Poorly Written Comment
C5: Commented-Out Code
Environment:
E1: Build Requires More Than One Step
E2: Tests Require More Than One Step
Functions:
F1: Too Many Arguments
F2: Output Arguments
F3: Flag Arguments
F4: Dead Function
General - (hightlights to help memorize - red color, Julia produced the code with smells...)
G1: Multiple Languages in One Source File
G2: Obvious Behavior Is Unimplemented
G3: Incorrect Behavior at the Boundaries
G4: Overridden Safeties
G5: Duplication
G6: Code at Wrong Level of Abstraction
G7: Base Classes Depending on Their Derivatives
G8: Too Much Information
G9: Dead Code
G10: Vertical Separation
G11: Inconsistency - the principle of least surprise
G12: Clutter
G13: Artificial Coupling - lazy and careless of placement of a variable, constant or function
G14: Feature Envy -
G15: Selector Arguments
Great blog about clean code: CMU - top 4 computer science - a professor
http://jxyzabc.blogspot.ca/2012/12/treat-yo-self-clean-up-your-code.html
"During the course of grad school, my relationship with my code has become increasingly important. Clean, modular, and well-documented code (with tests!) is not only less likely to have bugs but will be useful for longer. Clean code provides a solid foundation for you and potentially other researchers. Modular code makes it easier to reuse parts of your code. Also, knowing exactly what your code does just feels good."
Editorial notes:
1. Clean, modular, and well-documented code (with tests!)
Julia, let us hold high standards as a software programmer -
Review common code smells before you write code for a project.
2. Work on blog writing, and see if you can write good blogs as
http://jxyzabc.blogspot.ca
3. work on the blog:
http://jxyzabc.blogspot.ca/search/label/academic%20advice
study writing - write down things to learn from the above article
4. Borrow some ideas from website usability & user experience - Julia, you need to read 60 pages - page by page first.
Study Website Usability & User Experience (UX) Definition
(60 pages - plan to read 1- 2 hours, understand the concepts first)
http://blog.usabilla.com/the-abc-of-usability/
http://blog.usabilla.com/6-ted-talks-every-ux-professional-should-watch/
5. How Code smells research leads to the website Usability research? User experience research?
Sunday, September 18, 2016
HackerRank Stryker Code Sprint Grind summary
Sept. 18, 2016
Spent over 14 hours to work on the algorithm problem solving, hours to spend time to read problem statements. Score 233/ 560, rank 174/ 1936 participant.
https://www.hackerrank.com/contests/stryker-codesprint/challenges
1. First algorithm:
http://juliachencoding.blogspot.ca/2016/09/hackerrank-stryker-code-sprint-grind.html
2. Second algorithm:
http://juliachencoding.blogspot.ca/2016/09/hackerrank-stryker-code-sprint-grind_18.html
3. Third algorithm: Two submissions.
http://juliachencoding.blogspot.ca/2016/09/hackerrank-stryker-code-sprint-grind_7.html
http://juliachencoding.blogspot.ca/2016/09/hackerrank-stryker-code-sprint-grind_41.html
4. Fourth algorithm:
http://juliachencoding.blogspot.ca/2016/09/hackerrank-stryker-code-sprint-grind_3.html
5. Fifth algorithm:
http://juliachencoding.blogspot.ca/2016/09/hackerrank-stryker-code-sprint-grind-vi.html
6. Sixth algorithm:
http://juliachencoding.blogspot.ca/2016/09/hackerrank-stryker-code-sprint-grind-vi.html
7. Seventh algorithm:
http://juliachencoding.blogspot.ca/2016/09/hackerrank-maximizing-longest-path.html
Plan to work on this algorithm later, study more problems related. Read algorithm books.
Editorial Notes:
This is a fantastic journey to spend over 12 hours to battle on the algorithms. Julia built a very good physical strength and also good concentration on reading/ analysis/ coding. She enjoyed the live competition while she could analyze how many are successful on the algorithm, so she chose easy battle first. And also, Julia just learned to entertain herself while playing nice music along.
Julia tried to solve seventh algorithm in order to break in top 100 ranking, but she was too late; 1:00am, she should have started early; She missed the first 3 hours because of time difference between EST and PST.
But, in other hand, Julia studied top performers - best one only uses 3 hours in total for all the algorithms.
Julia will work on more training on herself. Just enjoy the contest.
Spent over 14 hours to work on the algorithm problem solving, hours to spend time to read problem statements. Score 233/ 560, rank 174/ 1936 participant.
https://www.hackerrank.com/contests/stryker-codesprint/challenges
1. First algorithm:
http://juliachencoding.blogspot.ca/2016/09/hackerrank-stryker-code-sprint-grind.html
2. Second algorithm:
http://juliachencoding.blogspot.ca/2016/09/hackerrank-stryker-code-sprint-grind_18.html
3. Third algorithm: Two submissions.
http://juliachencoding.blogspot.ca/2016/09/hackerrank-stryker-code-sprint-grind_7.html
http://juliachencoding.blogspot.ca/2016/09/hackerrank-stryker-code-sprint-grind_41.html
4. Fourth algorithm:
http://juliachencoding.blogspot.ca/2016/09/hackerrank-stryker-code-sprint-grind_3.html
5. Fifth algorithm:
http://juliachencoding.blogspot.ca/2016/09/hackerrank-stryker-code-sprint-grind-vi.html
6. Sixth algorithm:
http://juliachencoding.blogspot.ca/2016/09/hackerrank-stryker-code-sprint-grind-vi.html
7. Seventh algorithm:
http://juliachencoding.blogspot.ca/2016/09/hackerrank-maximizing-longest-path.html
Plan to work on this algorithm later, study more problems related. Read algorithm books.
Editorial Notes:
This is a fantastic journey to spend over 12 hours to battle on the algorithms. Julia built a very good physical strength and also good concentration on reading/ analysis/ coding. She enjoyed the live competition while she could analyze how many are successful on the algorithm, so she chose easy battle first. And also, Julia just learned to entertain herself while playing nice music along.
Julia tried to solve seventh algorithm in order to break in top 100 ranking, but she was too late; 1:00am, she should have started early; She missed the first 3 hours because of time difference between EST and PST.
But, in other hand, Julia studied top performers - best one only uses 3 hours in total for all the algorithms.
Julia will work on more training on herself. Just enjoy the contest.
I don't feel fear when I am on court. That's where I feel at home #CreateYourMark #RG16 @adidastennis @adidasFR pic.twitter.com/ZVNcZvWZE0— Kristina Mladenovic (@KikiMladenovic) May 20, 2016
HackerRank Stryker Code Sprint Grind (VI) - Julia and the Search Tree
Sept. 18, 2016
Problem statement:
https://www.hackerrank.com/contests/stryker-codesprint/challenges/julia-and-bst
Julia's solution using C#:
https://gist.github.com/jianminchen/4a52a1d20b60e5c6ccd9387b6fb24725
Could not believe her eye, Julia scored full score 100 out of 100 on a difficult algorithm.
Here is the timeline:
/*
*
* Julia and the search tree
* problem statement:
* https://www.hackerrank.com/contests/stryker-codesprint/challenges/julia-and-bst
*
* 10:25pm - 10:47pm
* read problem statement
* Too many nodes in the tree
* 1. Need to use iterative solution/ not recursive/ avoid stack overflow
* 2. First construct the tree
* 3. Then, maybe, add the calculation of sum
*
* Submit on 11:23pm
* Score 80 out of 80
* Cannot believe that it is difficult level!
*
*/
/*
* 10:53pm - start to write code
* 11:14pm - finish to construct the binary search tree
* Need to think about timout?
* stack overflow?
* what else
* Need to add more tasks
*/
Summary:
Total time is less than 1 hour.
1. 22 minutes to read the problem statement
2. 26 minutes to write code, 10:52pm - 11:23pm
No bug, just score 80 out of 80. Unbelievable success.
Problem statement:
https://www.hackerrank.com/contests/stryker-codesprint/challenges/julia-and-bst
Julia's solution using C#:
https://gist.github.com/jianminchen/4a52a1d20b60e5c6ccd9387b6fb24725
Could not believe her eye, Julia scored full score 100 out of 100 on a difficult algorithm.
Here is the timeline:
/*
*
* Julia and the search tree
* problem statement:
* https://www.hackerrank.com/contests/stryker-codesprint/challenges/julia-and-bst
*
* 10:25pm - 10:47pm
* read problem statement
* Too many nodes in the tree
* 1. Need to use iterative solution/ not recursive/ avoid stack overflow
* 2. First construct the tree
* 3. Then, maybe, add the calculation of sum
*
* Submit on 11:23pm
* Score 80 out of 80
* Cannot believe that it is difficult level!
*
*/
/*
* 10:53pm - start to write code
* 11:14pm - finish to construct the binary search tree
* Need to think about timout?
* stack overflow?
* what else
* Need to add more tasks
*/
Summary:
Total time is less than 1 hour.
1. 22 minutes to read the problem statement
2. 26 minutes to write code, 10:52pm - 11:23pm
No bug, just score 80 out of 80. Unbelievable success.
HackerRank Stryker Code Sprint Grind (V) - The Hidden Message - 70%
Sept. 18, 2016
Problem statement
Julia's C# solution is here.
Here is the timeline Julia worked on the problem solving:
Section 1:
/* 7:08pm - start to read the problem statement
*
* 7:47pm start to write down her approach
* start position is increasing
* How to find word match?
*
* Time complexity -
* Data structure
* Space complexity:
*
* 7:55pm start to code
*
* 10:04pm start to conduct testing
*/
Section 2:
Copy the code from previous practice - substring search, using Boyer algorithm to speed up, avoid timeout issues.
/*
* 8:24pm
* copy code from blog:
* http://juliachencoding.blogspot.ca/2016/04/hackerrank-string-function-calculation_10.html
*
* 8:36 prepare to exit the function
*/
private static bool findUsingBoyerAlgo(string substring, string s, ref int start)
Section 3:
/*
* 9:02pm - start to code
* 9:43pm - still work on the calculation of cost
* - try to think about how many chars to be removed - second step
* 9:57pm use brute force solution first
*/
public static string calculateCost(IList<Match> data,
string message
)
Section 4:
/*
* 10:19pm
* Summary of submission:
* 40.80/60
* Wrong answer for test case: 11, 15
* Try to fix the bug
*/
Summary:
1. 40 minutes to read the problem statement
2. 2 hours coding - including eating a dinner - 20 minutes
55 minutes to work on calculation of cost, looked into interval algorithm, and then, figured out using brute force solution instead.
2. 10:04pm testing
Score 40.80/ 60
Decided to give up bug fix, and then, moved on next question.
Study C# submission - 60 out of 60
1. Use Trie
2. C#: use dynamic programming.
Related to Leetcode 72: "Edit Distance"
3. Study the blog: Levenshtein Distance wiki
4. Study Java 8 solution - use Rabin Karp algorithm search class, DP
5. C++ code - Learn from the best, competitive programmer
6. C++ - KMP algorithm, DP
7. The programmer - 5 Gold - rank 32/1700
a Googler, a blog.
Talk about Google code review - in Chinese, link is here.
Problem statement
Julia's C# solution is here.
Here is the timeline Julia worked on the problem solving:
Section 1:
/* 7:08pm - start to read the problem statement
*
* 7:47pm start to write down her approach
* start position is increasing
* How to find word match?
*
* Time complexity -
* Data structure
* Space complexity:
*
* 7:55pm start to code
*
* 10:04pm start to conduct testing
*/
Section 2:
Copy the code from previous practice - substring search, using Boyer algorithm to speed up, avoid timeout issues.
/*
* 8:24pm
* copy code from blog:
* http://juliachencoding.blogspot.ca/2016/04/hackerrank-string-function-calculation_10.html
*
* 8:36 prepare to exit the function
*/
private static bool findUsingBoyerAlgo(string substring, string s, ref int start)
Section 3:
/*
* 9:02pm - start to code
* 9:43pm - still work on the calculation of cost
* - try to think about how many chars to be removed - second step
* 9:57pm use brute force solution first
*/
public static string calculateCost(IList<Match> data,
string message
)
Section 4:
/*
* 10:19pm
* Summary of submission:
* 40.80/60
* Wrong answer for test case: 11, 15
* Try to fix the bug
*/
Summary:
1. 40 minutes to read the problem statement
2. 2 hours coding - including eating a dinner - 20 minutes
55 minutes to work on calculation of cost, looked into interval algorithm, and then, figured out using brute force solution instead.
2. 10:04pm testing
Score 40.80/ 60
Decided to give up bug fix, and then, moved on next question.
Study C# submission - 60 out of 60
1. Use Trie
2. C#: use dynamic programming.
Related to Leetcode 72: "Edit Distance"
3. Study the blog: Levenshtein Distance wiki
4. Study Java 8 solution - use Rabin Karp algorithm search class, DP
5. C++ code - Learn from the best, competitive programmer
6. C++ - KMP algorithm, DP
7. The programmer - 5 Gold - rank 32/1700
a Googler, a blog.
Talk about Google code review - in Chinese, link is here.
HackerRank Stryker Code Sprint Grind (IV) - Kth Zero - Second Try
Sept. 18, 2016
Continued to work on the algorithm, tried to solve the time out issues.
Here is the C# code:
https://gist.github.com/jianminchen/d53550f39f4425734030c874463b5881
Timeline of Julia bug fixing, aiming more points successfully:
/*
5:48pm - start to work on time out issue
* 6:52pm - bug fix:
* stack over flow
* Are arrays or lists passed by default by refrence in C#?
* Need to pass ref
*/
The idea to solve timeout is to using O(n) time to copy the array instead of using O(nlogn) to sort the array.
Summary:
1. 25 minutes to do analysis
5:48pm - 6:07pm
2. 45 minutes to modify code
Worked on coding 6:07pm - 6:52pm
2. and then, created a new bug, and then fix
Are arrays or lists passed by default by reference in C#?
Score 52/60, two test cases time out due to 3s
Julia's comment: Haha..., Julia, you could not figure out why? Read the study code #1, then figure out why. (worked on it again on Sept. 19, 2016)
Study code: (worked on it again on Sept. 19, 2016)
1. C#
https://gist.github.com/jianminchen/9cdbdcefd84e3cb8e709eabf705ce4b0
Julia learned the lesson after she studied the above code:
In her solution, a hashset is used to get access O(1) for those zero numbers in the array. However, the hash function can not guarantee to perform as good as O(1).
Because the size of array is 10^5, it is the same thing to access O(1) if using binary search, which is log(N) = log(10^5) = 5 = O(1).
(Sept. 20, 2016 correction: log(N)=log(10^5) = 5 * log10 =5 *3.xx = O(1), since log 8 = 3. )
The fix of the bug is to remove the Hashset in the solution, call Array.BinarySearch to find the value.
https://gist.github.com/jianminchen/d53550f39f4425734030c874463b5881
2.
https://gist.github.com/jianminchen/63172e67001956e75abae02d079c668d
Google search using keyword:
C# sortedList analog in C++
Found the articles to read:
http://landenlabs.com/code/containers/index.html
The SortedList<TKey,TValue> is the other sorted associative container class in the generic containers. Once again SortedList<TKey,TValue>, like SortedDictionary<TKey,TValue>, uses a key to sort key-value pairs. Unlike SortedDictionary, however, items in a SortedList are stored as sorted array of items. This means that insertions and deletions are linear - O(n) - because deleting or adding an item may involve shifting all items up or down in the list. Lookup time, however is O(log n) because the SortedList can use a binary search to find any item in the list by its key. So why would you ever want to do this? Well, the answer is that if you are going to load the SortedList up-front, the insertions will be slower, but because array indexing is faster than following object links, lookups are marginally faster than a SortedDictionary. Once again I'd use this in situations where you want fast lookups and want to maintain the collection in order by the key, and where insertions and deletions are rare.
Continuous work:
1. remove hashset from solution, C# solution, still time out on last 2 test cases.
https://gist.github.com/jianminchen/a865fd512e176ecf973338036db563c7
2. A lot of C++ solutions - use bit manipulation, binary tree, segment tree, more complicated than I thought.
1. Segment tree - read the blog 10+ minutes
http://www.geeksforgeeks.org/segment-tree-set-1-sum-of-given-range/
Continued to work on the algorithm, tried to solve the time out issues.
Here is the C# code:
https://gist.github.com/jianminchen/d53550f39f4425734030c874463b5881
Timeline of Julia bug fixing, aiming more points successfully:
/*
5:48pm - start to work on time out issue
* 6:52pm - bug fix:
* stack over flow
* Are arrays or lists passed by default by refrence in C#?
* Need to pass ref
*/
The idea to solve timeout is to using O(n) time to copy the array instead of using O(nlogn) to sort the array.
Summary:
1. 25 minutes to do analysis
5:48pm - 6:07pm
2. 45 minutes to modify code
Worked on coding 6:07pm - 6:52pm
2. and then, created a new bug, and then fix
Are arrays or lists passed by default by reference in C#?
Score 52/60, two test cases time out due to 3s
Julia's comment: Haha..., Julia, you could not figure out why? Read the study code #1, then figure out why. (worked on it again on Sept. 19, 2016)
Study code: (worked on it again on Sept. 19, 2016)
1. C#
https://gist.github.com/jianminchen/9cdbdcefd84e3cb8e709eabf705ce4b0
Julia learned the lesson after she studied the above code:
In her solution, a hashset is used to get access O(1) for those zero numbers in the array. However, the hash function can not guarantee to perform as good as O(1).
Because the size of array is 10^5, it is the same thing to access O(1) if using binary search, which is log(N) = log(10^5) = 5 = O(1).
(Sept. 20, 2016 correction: log(N)=log(10^5) = 5 * log10 =5 *3.xx = O(1), since log 8 = 3. )
The fix of the bug is to remove the Hashset in the solution, call Array.BinarySearch to find the value.
https://gist.github.com/jianminchen/d53550f39f4425734030c874463b5881
2.
https://gist.github.com/jianminchen/63172e67001956e75abae02d079c668d
Google search using keyword:
C# sortedList analog in C++
Found the articles to read:
http://landenlabs.com/code/containers/index.html
The SortedList<TKey,TValue> is the other sorted associative container class in the generic containers. Once again SortedList<TKey,TValue>, like SortedDictionary<TKey,TValue>, uses a key to sort key-value pairs. Unlike SortedDictionary, however, items in a SortedList are stored as sorted array of items. This means that insertions and deletions are linear - O(n) - because deleting or adding an item may involve shifting all items up or down in the list. Lookup time, however is O(log n) because the SortedList can use a binary search to find any item in the list by its key. So why would you ever want to do this? Well, the answer is that if you are going to load the SortedList up-front, the insertions will be slower, but because array indexing is faster than following object links, lookups are marginally faster than a SortedDictionary. Once again I'd use this in situations where you want fast lookups and want to maintain the collection in order by the key, and where insertions and deletions are rare.
Continuous work:
1. remove hashset from solution, C# solution, still time out on last 2 test cases.
https://gist.github.com/jianminchen/a865fd512e176ecf973338036db563c7
2. A lot of C++ solutions - use bit manipulation, binary tree, segment tree, more complicated than I thought.
1. Segment tree - read the blog 10+ minutes
http://www.geeksforgeeks.org/segment-tree-set-1-sum-of-given-range/
HackerRank Stryker Code Sprint Grind (III) - Kth Zero - First Try
Sept. 18, 2016
Problem statement:
https://www.hackerrank.com/contests/stryker-codesprint/challenges/kth-zero
Julia observed that more than 80% successful rate on this algorithm, so she chose to work this one (fourth one) first instead of "The Hidden Message" (3rd question).
https://gist.github.com/jianminchen/f0de5ad6cda7e75df5d6c18a36c41a99
Here are the time line Julia worked on the problem solving:
/*
* 3:46pm - 4:36pm
* Read the question, and figure out the design:
* Like database table using index, need to prepare index.
* Only update query -
* 1: case 1: replace the position which has value 0;
* 2. additional element with value zero in the array
* Just put Hash table to the array, and then, sort the array O(nlogn).
* Maintain a hash table and array for value 0 in the array
* Otherwise, time complexity should be ok.
* To make sort minimum - only sort when next query of kth zero comes in,
* also set isDirty to track if update is need or not.
*/
/*
* 4:36pm start to write code
*5:30pm conduct testing.
*5:48pm, timeout, and score 26/40 points
*/
Summary:
2.5 hours to work on first try.
1. 50 minutes reading time
2. 56 minutes to write first try
3. 20 minutes to conduct testing
Score 26/40 points, need to work on timeout issue
Problem statement:
https://www.hackerrank.com/contests/stryker-codesprint/challenges/kth-zero
Julia observed that more than 80% successful rate on this algorithm, so she chose to work this one (fourth one) first instead of "The Hidden Message" (3rd question).
https://gist.github.com/jianminchen/f0de5ad6cda7e75df5d6c18a36c41a99
Here are the time line Julia worked on the problem solving:
/*
* 3:46pm - 4:36pm
* Read the question, and figure out the design:
* Like database table using index, need to prepare index.
* Only update query -
* 1: case 1: replace the position which has value 0;
* 2. additional element with value zero in the array
* Just put Hash table to the array, and then, sort the array O(nlogn).
* Maintain a hash table and array for value 0 in the array
* Otherwise, time complexity should be ok.
* To make sort minimum - only sort when next query of kth zero comes in,
* also set isDirty to track if update is need or not.
*/
/*
* 4:36pm start to write code
*5:30pm conduct testing.
*5:48pm, timeout, and score 26/40 points
*/
Summary:
2.5 hours to work on first try.
1. 50 minutes reading time
2. 56 minutes to write first try
3. 20 minutes to conduct testing
Score 26/40 points, need to work on timeout issue
HackerRank Stryker Code Sprint Grind (II) - Point Filtering
Sept. 18, 2016
Problem statement:
https://www.hackerrank.com/contests/stryker-codesprint/challenges/point-filtering
Julia's C# implementation:
https://gist.github.com/jianminchen/41a5b656f3aeacde37588adef261d4a2
It was tough experience. Julia could not believe that how much time she spent time.
Here are the statistics, she tracked time spent while she wrote code; first time, she felt that it was important thing to do. More focus on the contest, come back to figure out what the issues are.
Here is the time line Julia worked on the algorithm:
/*
* 11:20 start to read the question
* read 10+ minutes
* Put some design notes together
* bucket (size of b)
* Add/ Delete/ Replenish
* Req: maintain the size of b all the time
*
* Main List
* Sort
* remove/ first b
* remove top1
* not empty
*
* Time complexity: Sort using nlog(n)
* Space complexity: Use Dictionary to store the points
* Use integer to express 1.000 - 1000 instead of 1
*
* 2:35pm start to test the program
* 2:59 wrong answer after 1 key is removed from bucket
* continue to fix the bug related to replenish the bucket
* 3:07 passed the sample test case
*
* Summary:
* Reading and design: 30 minutes
* Coding: 1:27pm - 3:07pm
* Testing: 30 minutes (2:35pm - 3:07pm)
*/
Summary:
1. 2 hours to read the problem, and thought about solution; while making a lunch, have a lunch
2. 90 minutes coding
3. 30 minutes testing
Score 40 (40 in total)
Actionable Items:
Big issue - Need to work on speed, time should be cut down from 3 hours to 30 minutes.
1. Study the C# submission:
No. 1:
https://gist.github.com/jianminchen/ada496ab333e962988ca088a07deeac3
No. 2:
https://gist.github.com/jianminchen/5dc56ab8d69496c0c12e35ab5ccbeb73
No. 3:
https://gist.github.com/jianminchen/980c5626de67f33f2a39dee33eb770a8
No. 4:
https://gist.github.com/jianminchen/715754585de580142d514905c3ab4fea
No. 5:
https://gist.github.com/jianminchen/877ff5d9f0026ed007e55ef7386fd5a9
No. 6:
https://gist.github.com/jianminchen/e0a94f4f3b9432a81b51b68951647a8a
No. 7:
https://gist.github.com/jianminchen/e9ddff599b7ec3cfe53dd7d5c20f66bd
C++ implementation:
No. 8: less than 15 minutes:
https://gist.github.com/jianminchen/61bdc567cb42b172ffc35f67a6442ff7
No. 9: less than 15 minutes:
https://gist.github.com/jianminchen/e88c8e354af2a810fef03f64e4d228c6
No. 10:
https://gist.github.com/jianminchen/652c78955e9999e3ab5759fb9358f69e
No. 11:
https://gist.github.com/jianminchen/59fa3914b92b71dce3f707c62fdf99ab
Researcher, professor, Intel research:
https://www.hackerrank.com/kmalinau
Julia, read 30 submission using C++, full score, less than 60 minutes.
https://www.hackerrank.com/contests/stryker-codesprint/challenges/point-filtering/leaderboard
Problem statement:
https://www.hackerrank.com/contests/stryker-codesprint/challenges/point-filtering
Julia's C# implementation:
https://gist.github.com/jianminchen/41a5b656f3aeacde37588adef261d4a2
It was tough experience. Julia could not believe that how much time she spent time.
Here are the statistics, she tracked time spent while she wrote code; first time, she felt that it was important thing to do. More focus on the contest, come back to figure out what the issues are.
Here is the time line Julia worked on the algorithm:
/*
* 11:20 start to read the question
* read 10+ minutes
* Put some design notes together
* bucket (size of b)
* Add/ Delete/ Replenish
* Req: maintain the size of b all the time
*
* Main List
* Sort
* remove/ first b
* remove top1
* not empty
*
* Time complexity: Sort using nlog(n)
* Space complexity: Use Dictionary to store the points
* Use integer to express 1.000 - 1000 instead of 1
*
* 2:35pm start to test the program
* 2:59 wrong answer after 1 key is removed from bucket
* continue to fix the bug related to replenish the bucket
* 3:07 passed the sample test case
*
* Summary:
* Reading and design: 30 minutes
* Coding: 1:27pm - 3:07pm
* Testing: 30 minutes (2:35pm - 3:07pm)
*/
Summary:
1. 2 hours to read the problem, and thought about solution; while making a lunch, have a lunch
2. 90 minutes coding
3. 30 minutes testing
Score 40 (40 in total)
Actionable Items:
Big issue - Need to work on speed, time should be cut down from 3 hours to 30 minutes.
1. Study the C# submission:
No. 1:
https://gist.github.com/jianminchen/ada496ab333e962988ca088a07deeac3
No. 2:
https://gist.github.com/jianminchen/5dc56ab8d69496c0c12e35ab5ccbeb73
No. 3:
https://gist.github.com/jianminchen/980c5626de67f33f2a39dee33eb770a8
No. 4:
https://gist.github.com/jianminchen/715754585de580142d514905c3ab4fea
No. 5:
https://gist.github.com/jianminchen/877ff5d9f0026ed007e55ef7386fd5a9
No. 6:
https://gist.github.com/jianminchen/e0a94f4f3b9432a81b51b68951647a8a
No. 7:
https://gist.github.com/jianminchen/e9ddff599b7ec3cfe53dd7d5c20f66bd
C++ implementation:
No. 8: less than 15 minutes:
https://gist.github.com/jianminchen/61bdc567cb42b172ffc35f67a6442ff7
No. 9: less than 15 minutes:
https://gist.github.com/jianminchen/e88c8e354af2a810fef03f64e4d228c6
No. 10:
https://gist.github.com/jianminchen/652c78955e9999e3ab5759fb9358f69e
No. 11:
https://gist.github.com/jianminchen/59fa3914b92b71dce3f707c62fdf99ab
Researcher, professor, Intel research:
https://www.hackerrank.com/kmalinau
Julia, read 30 submission using C++, full score, less than 60 minutes.
https://www.hackerrank.com/contests/stryker-codesprint/challenges/point-filtering/leaderboard
HackerRank Stryker Code Sprint Grind (I) - Minimum Index Difference
Sept. 18, 2018
Worked on first algorithm of HackerRand Stryker Code sprint - Minimum Index Difference
https://www.hackerrank.com/contests/stryker-codesprint/challenges/minimum-index-difference
Julia's C# code, score 20 of 20.
https://gist.github.com/jianminchen/a377bac6ff6a2b459db462b0e2506470
Worked on first algorithm of HackerRand Stryker Code sprint - Minimum Index Difference
https://www.hackerrank.com/contests/stryker-codesprint/challenges/minimum-index-difference
Julia's C# code, score 20 of 20.
https://gist.github.com/jianminchen/a377bac6ff6a2b459db462b0e2506470
HackerRank Stryker Codesprint Grind (VII): Maximizing The Longest Path - Stryker Codesprint
Sept. 18, 2016
Started from 11:30pm, worked on this difficult level algorithm:
Maximizing the longest path
simple path in the graph
After 12 hours continuously coding, only 2 breaks for meals, and then, Julia gave up her try; Tried to break into top 50 - using DFS, NP problem solving efforts, until 1am.
Started from 11:30pm, worked on this difficult level algorithm:
Maximizing the longest path
Read problem statement 20 minutes, and then, read articles:
simple path in the graph
https://en.wikipedia.org/wiki/Path_(graph_theory)
https://en.wikipedia.org/wiki/Longest_path_problem
Will come back later on to work on this algorithm.
After 12 hours continuously coding, only 2 breaks for meals, and then, Julia gave up her try; Tried to break into top 50 - using DFS, NP problem solving efforts, until 1am.
Celebration:
Her first motivated grind - 11:00am - 1am over 14 hour long grind.Statistics:
Stryker Codesprint: Score 233 - 150/ 1766 participants (at 1am, 9/18/2016)
178/ 1766
Study code:
1. C++ 14
Friday, September 16, 2016
IBM Ponder this - Sept 2016
Sept. 16, 2016
I knew IBM very well - since I lived in the city of Boca Raton, Florida over 14 years. And also Boca Raton is the city used to be headquarter of IBM in early 1990. And I used to work in the city of Delary for Siva corporation from June 2016 to August 2017, just one mile away from IBM office in Boca Raton.
Always, I remind myself, from 1996 to 2010, I had a long journey over there. But, it is better to celebrate with an algorithm.
So, I like to get into the algorithm practice sometime in short future. Use this algorithm to celebrate my 20 years experience in North of America, 14 years in USA whereas 6 years in Canada. In 1996, I moved to the city of Boca Raton; Just cannot believe it, like yesterday.
IBM Ponder this - Sept. 2016
http://www.research.ibm.com/haifa/ponderthis/challenges/September2016.html
Read this blog about solution of IBM Ponder this - Sept. 2016
https://anothercasualcoder.blogspot.ca/2016/09/ponder-this-sept-2016-permutations-dfs.html
blog reading:
http://www.hercampus.com/school/duke/melinda-gates-being-woman-tech?linkId=28873720
http://blog.csdn.net/philipsweng
http://www.mimuw.edu.pl/~erykk/xe-contest.php
I knew IBM very well - since I lived in the city of Boca Raton, Florida over 14 years. And also Boca Raton is the city used to be headquarter of IBM in early 1990. And I used to work in the city of Delary for Siva corporation from June 2016 to August 2017, just one mile away from IBM office in Boca Raton.
Always, I remind myself, from 1996 to 2010, I had a long journey over there. But, it is better to celebrate with an algorithm.
So, I like to get into the algorithm practice sometime in short future. Use this algorithm to celebrate my 20 years experience in North of America, 14 years in USA whereas 6 years in Canada. In 1996, I moved to the city of Boca Raton; Just cannot believe it, like yesterday.
IBM Ponder this - Sept. 2016
http://www.research.ibm.com/haifa/ponderthis/challenges/September2016.html
Read this blog about solution of IBM Ponder this - Sept. 2016
https://anothercasualcoder.blogspot.ca/2016/09/ponder-this-sept-2016-permutations-dfs.html
blog reading:
http://www.hercampus.com/school/duke/melinda-gates-being-woman-tech?linkId=28873720
http://blog.csdn.net/philipsweng
http://www.mimuw.edu.pl/~erykk/xe-contest.php
Blog reading - Writing is best way to share the journey to excellence
Sept. 16, 2016
Computer professor of University of san Diego - very good advices - with details - plan to spend 3- 5 hours to go over the blogs
http://pgbovine.net/programming-interview-tips.htm
http://pgbovine.net/do-what-you-love.htm
http://pgbovine.net/motivation-momentum-marketability.htm
http://pgbovine.net/apps/faculty-2012/pguo-cover-letter_2012.pdf
http://pgbovine.net/productivity-tips.htm
http://pgbovine.net/unicorn-jobs.htm
Best lecture in the world about rest API - quick lesson - Julia, learn it in 30 minutes
http://pgbovine.net/rest-web-api-basics.htm
http://pgbovine.net/apps/faculty-2012/pguo-teaching-statement_2012.pdf
Statistics of the professor's great writing:
"In addition, I have written several articles on my website that are popular with students. For example,
my article on advice for applying to Ph.D. programs [2] has over 45,000 page views, advice on applying
to graduate fellowships [3] has over 95,000 views, and professional email writing tips [4] has over 42,000
views. I receive dozens of emails each year from students around the world asking for advice; I try to
answer as many as I can and then update my website articles to share that knowledge."
50 minutes video: The Ph.D. Grind
https://www.youtube.com/watch?v=zHp2rxR2LTc
Computer professor of University of san Diego - very good advices - with details - plan to spend 3- 5 hours to go over the blogs
http://pgbovine.net/programming-interview-tips.htm
http://pgbovine.net/do-what-you-love.htm
http://pgbovine.net/motivation-momentum-marketability.htm
http://pgbovine.net/apps/faculty-2012/pguo-cover-letter_2012.pdf
http://pgbovine.net/productivity-tips.htm
http://pgbovine.net/unicorn-jobs.htm
Best lecture in the world about rest API - quick lesson - Julia, learn it in 30 minutes
http://pgbovine.net/rest-web-api-basics.htm
http://pgbovine.net/apps/faculty-2012/pguo-teaching-statement_2012.pdf
Statistics of the professor's great writing:
"In addition, I have written several articles on my website that are popular with students. For example,
my article on advice for applying to Ph.D. programs [2] has over 45,000 page views, advice on applying
to graduate fellowships [3] has over 95,000 views, and professional email writing tips [4] has over 42,000
views. I receive dozens of emails each year from students around the world asking for advice; I try to
answer as many as I can and then update my website articles to share that knowledge."
50 minutes video: The Ph.D. Grind
https://www.youtube.com/watch?v=zHp2rxR2LTc
Subscribe to:
Posts (Atom)