Saturday, July 13, 2019

480. Sliding Window Median

It is a hard level algorithm. I like to spend 30 minutes to work on the algorithm.

Sliding Window Median
C# using List.BinarySearch API practice in 2019

It is the hard level algorithm. I like to share my study code and talk about why it is hard for me to solve the algorithm.
I chose to study one of C# solutions, and then I put together the test case and figure out how it works.
Here are highlights:
  1. Go through first k elements in the array and put into List by calling BinarySearch API to find index for next position; Therefore the list is sorted.
  2. Once slide window size is k, remove left pointer, and then add median value into the list.
  3. It is very good study code for me to learn how to build a sorted list using List API BinarySearch.
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;

namespace _480_slide_window_median___study
{
    class Program
    {
        static void Main(string[] args)
        {
            var numbers = new int[]{1,3,-1,-3,5,3,6,7}; 
            var result = MedianSlidingWindow(numbers, 3);

            // result should be [1.0,-1.0,-1.0,3.0,5.0,6.0]
        }

        /// <summary>
        /// July 16, 2019
        /// study code:
        /// https://leetcode.com/problems/sliding-window-median/discuss/96357/C-BinarySearch-solution
        /// The idea is to insert the number into the index position found by binary search API.
        /// So the list is sorted in ascending order. 
        /// </summary>
        /// <param name="numbers"></param>
        /// <param name="k"></param>
        /// <returns></returns>
        public static double[] MedianSlidingWindow(int[] numbers, int k)
        {
            var list = new List<double>();

            if (numbers != null && numbers.Length > 0 && k > 0)
            {
                int half = (k >> 1);

                int median = half + (k & 1) - 1;

                var slideWindow = new List<double>();

                // slide window maintenance - put into window with sorted order first
                // remove left pointer value
                for (int i = 0; i < numbers.Length; ++i)
                {
                    if (i >= k)
                    {
                        slideWindow.Remove(numbers[i - k]);
                    }

                    int index = slideWindow.BinarySearch(numbers[i]);
                    if (index < 0)
                    {
                        index = ~index;
                    }

                    slideWindow.Insert(index, numbers[i]);

                    if (i >= k - 1)
                    {
                        list.Add(half == median ? slideWindow[half] : ((slideWindow[half] + slideWindow[median]) / 2));
                    }
                }
            }

            return list.ToArray<double>();
        }
    }
}

518 Coin change 2

Here is my dynamic programming solution.


iShares Core Canadian Long Term Bond Index ETF

76. Minimum Window Substring

If I design http protocol, how I handle double click on web form?

10 Things You Can Do to Boost Self-Confidence

Here is the article I like to read and I like to learn how to improve my self-confidence.


If you double click submit on web form, what will happen?

July 13, 2019

Introduction


It is my self-confidence research. I am lack of confidence, and this shows up problems again and again. I like to work on this.

Interview question


I went to onsite without too much preparation, this is my first onsite interview in 2019. I found out that I have self-confidence issue.

Since I have Amazon phone screen on Monday, and Tuesday I went to work, Wednesday I went to onsite. I do not learn to take time to prepare for reviewing all kinds of questions, such as Asp.Net common interview questions etc.

If you double click submit on web form, what will happen?

I do not like to google search, but I like to argue two results, there is only two choices, first click and second click.

I went to best BC employer to have an interview. I just could not believe that I also have confidence issue. Simple reasoning problems, I work so hard to solve so many algorithm problem, I need to learn how to solve simple design problem as well.



Case study: Self-confidence issues in 2019

July 13, 2019

Introduction


I like to do a research how to build self-confidence. I am preparing Amazon onsite and also Facebook phone screen next week. I really like to build my self-confidence.


I love equity exposure

July 13, 2019

Introduction


This is my favorite quote from my favorite hostess Karen Finerman. And I like to write a blog about the topic.

I like to write a short blog to encourage more young people to learn how to invest stock market in long term.

My idol is Karen Finerman, here is her wiki page. She has net asset over $100 million dollars.

100 million vs 0.10 million 


I like to compare my equity asset less than $100,000 Canadian dollars to Karen Finerman $100 million dollars.









Thursday, July 11, 2019

65. Valid Number

I practiced the algorithm more than 3 years ago. And I just wrote a discuss post to share my practice.

Here is the link.

C# First submission in Sept. 2105

It is time for me to review the algorithm since I came cross the post.
I will write down some highlights for my practice.
  1. Skip leading space characters;
  2. Consider edge case: empty string is not a number;
  3. Skip one char if it is '+' or '-';
  4. More will be added later. There are a few more cases in the solution.
I also like to write down a few thoughts about the algorithm. Why it is hard, and what I learn from study of discussion posts.
public class Solution {
    public bool IsNumber(string s) {
        int len = s.Length;

            int i = 0, e = len - 1;

            while (i <= e && isWhitespace(s[i])) 
                i++;

            if (i > len - 1) 
                return false;

            while (e >= i && isWhitespace(s[e])) 
                e--;

            // skip leading +/-
            if (s[i] == '+' || s[i] == '-') i++;

            bool isNum = false; // is a digit
            bool isDot = false; // is a '.'
            bool isExp = false; // is a 'e'

            while (i <= e)
            {
                char c = s[i];
                if (isDigit(c))
                {
                    isNum = true;
                }
                else if (c == '.')
                {
                    if (isExp || isDot) 
                        return false;

                    isDot = true;
                }
                else if (c == 'e')
                {
                    if (isExp || isNum == false) 
                        return false;

                    isExp = true;
                    isNum = false;
                }
                else if (c == '+' || c == '-')
                {
                    if (s[i - 1] != 'e') return false;
                }
                else
                {
                    return false;
                }

                i++;
            }
            return isNum;
        }

        public bool isWhitespace(char c)
        {
            return c == ' '; 
        }

        public  bool isDigit(char c)
        {
            int no = c - '0';

            return no >= 0 && no <= 9; 
        }
}



Wednesday, July 10, 2019

Case study: Victoria portfolio dividend

I like to write a case study on this dividend log based on my Victoria portfolio, and also I like the design of Questrade.com web page.


Case study: My credit history from 1996 to 2010 in United States

July 10, 2019

Introduction


I just saw my ex-roommate in Florida Atlantic university to share a post about credit history, I like to write a case study on this topic as well. My ex-roommate Monika is VP of America Express, she spent a few hours to teach me how to drive and sat inside my car to teach me how to drive around FAU campus back in 1997.


Case study


I will write something here later. I need to spend 10 to 15 minutes to look into the argument inside the post first.




Case study: mock interview using remove k digits

I will write down a case study from a top engineer who performed the algorithm called remove k digits.

Case study


I will write down the transcript in the mock interview. And also the C# code to study as well. I am so happy to learn an engineer to write string.TrimStart, and all other good things in the sharing.

Here is the link.


Case study: Mock interview using lowest common ancestor

July 10, 2019

I spent one hour to interview an outstanding engineer, and he demonstrated how he solved the problem, the extended problem what if p and q are not in binary tree, and then distance between two nodes in binary tree.

Case study

I will write down some transcript the interviewee wrote in C# later.

AWS re:Inforce 2019 - Keynote with Steve Schmidt

Here is the link.

I got an email today for Amazon onsite invitation for AWS team. I am lucky to pass phone screen from Amazon AWS team. Also I got a link on the email related to this one hour video. I like to spend one hour to watch the video.


Top 20 .NET Interview Questions And Answers

Here is the link.

Q #15) What is Caching?
Ans: Caching means storing data temporarily in the memory so that the application can access the data from the cache instead of looking for its original location. This increases the performance of the application and its speed. System.Runtime.Caching namespace is used for Caching information in .Net.
Given below are the 3 different types of Caching:
  • Page Caching
  • Data Caching
  • Fragment Caching



Tuesday, July 9, 2019

979 Distribute coins in binary tree

979 Distribute coins in binary tree, here is my code written in C#.

Here is my C# practice written after the weekly contest. I studied other's sharing and wrote one successfully. 

I also like to case study my failed submission written in the contest if I have time later. The first one is here, and the second one is here. 


Monday, July 8, 2019

REST API & RESTful Web Services Explained

Here is the video I like to watch.


Burnaby's Fortinet bulking up to combat brewing cyber threats

Here is the article I like to read.

International cybersecurity firm Fortinet is on the hunt to hire as many as 1,000 tech experts to fill its newly expanded data hub in Burnaby and help it keep on top of a rapidly expanding “threat landscape,” as security strategist Derek Manky puts it.
From ordinary “phishing” to sophisticated malware and ransomware attacks such as WannaCry, Manky estimates Fortinet deals with “north of one million” new cyber threats every day.
And the number of Internet-connected devices in need of protection — from intelligent appliances and cars to smartphones — is always growing.
“(Ransomware) is a threat that has been on our radar for some time, but it’s getting nastier as time moves on,” Manky said. “They’re becoming more persistent and more damaging.”
To keep up with combating them, Fortinet announced this week the completion of a major expansion at its Burnaby campus, the now California-headquartered firm’s key research and development facility, taking over a second building in its suburban office park off Still Creek Drive.
That increases its footprint to about 282,000 square feet from the 87,000 square feet that Fortinet’s existing workforce of about 700 operates from now.

How to crush a white board interview?

Here is the link.

I got the link from Facebook today. I like to learn from the video. It is great teaching.


Interview tip
step 1:  Ask question to clarify the problem

1. ) What format is the word given to us?
2. ) How do we define a nearby word?
3. ) Do we need to remove duplicate words in the output?
4. ) ...


Explain the approach to the interviewer

Clarify your approach

5:08 / 11:57

We understand the problem
Asked Clarifying questions
Explain high level approach


step 3: Explain high level approach -

7:02/ 11:57
Check your code with an example

11:02
Test by checking edge cases

Analyze time and space complexity

Prepare questions for the interviewer -
What motivates them to join the company?


Fortinet SD-WAN Architecture & Demo

Here is the link.


Fortinet Security Fabric Deep Dive Demo

Here is the link.


72. Edit Distance

Here is my 2019 practice history post.

It is time for me to review all algorithms in order to prepare phone screen in next two weeks. I got a list of algorithms to work on. One of algorithms is Edit distance, I like to say that 416 Partition Equal Subset Sum is same idea as this one 72, Edit distance, but Edit distance is more popular and I practice more than 10 times on pramp.com from 2017 to 2019.
As a software programmer, I think that it is important not to memorize the solution, and also explain my thoughts very well. I have to build a good habit to read slowly, and also time myself to think about a solution, write a solution as well.
Here are my practice written in 2015, 2017, 2019.
2015 practice
2017 practice
2019 practice


Ken Xie, Fortinet | Fortinet Accelerate 2019

Here is the video's link.


Ken Xie, Fortinet | Fortinet Accelerate 2018

Here is 18 minutes interview with CEO of Fortinet.


Fortinet product matrix

Here is the link.


Roger Federer - My Photobooth | Wimbledon 2019

Here is the link.

Roger is my idol in tennis sports. Today I had good time to play tennis over one hour after 6:30 PM. Now I need to rush to sleep. That is my last video to watch.


Coco Gauff Wimbledon 2019 Third Round Press Conference

Here is the link.


Cori Gauff Wimbledon 2019 Second Round Press Conference

Here is the link.

Keep working hard. Your time will come.

Routine to work hard?

Hit ball hard. Extra time definitely will help.


Cori Gauff Wimbledon 2019 First Round Press Conference

Here is the link.


How hard it is to help a teenager to study in Canada high school?

July 8, 2019

Introduction


It is so tough for me to survive in Canada since I immigrated to Canada in 2010. I already turned over 44 years old. I never experienced how stable a job and what that means. Now I got a message from my younger sister, she likes to send her daughter to study in Canada high school.

Research, research, research


I never put myself into the consideration to study Canada high school courses like Algebra, English and Mathematics. My younger sister is college biochemical teacher, but she is different type of teacher. I used to study hard, and work on problem solving daily. I like to study those courses with my niece if she is here, and help her to achieve outstanding records in her study.

I ask my sister to send her all financial documents, assets, and my niece school work, let me evaluate first based on my own experience. I can be a very good manager to help a young teenager to grow in academic study. I found out that sometimes algorithm and data structure research lacks of challenge.


Sunday, July 7, 2019

One hour tennis sports to enjoy Sunday

I worked whole day at home office, and only took some breaks to chat two young professional roommate, talked about shopping, how to invest on stock market.

I like to go out to take one hour break to play some tennis. I need to watch my weight.


I got a message from Amazon AWS senior manager!

July 7, 2019

Introduction


It is very big company and I learn that I have to start from the beginning again to apply. I have to pass online code screen, and then phone screen, and then onsite interview. I got contacted a few times in 2019 by recruiters this year, but hiring manager has to short list candidates in order to give out online assessment.

Hiring manager


I also learn to think about how to be a manager one day. I know that is most challenging job in the world. Why?

I have problems to handle conflicts, and also help young generation to work and prepare for better career. I saw the patterns from behaviors, and I can tell things from people's thoughts. I have hard time to help my nephew - a new Canada immigrant, he landed in Canada Vancouver on May 15, and left on May 18, 2019.

But today I got a message from a hiring manager. It is such exciting news.

Sometimes I believe that recruiters are different from hiring managers in terms of candidates.


450. Delete Node in a BST

I like to review the algorithm. I came cross my post and was amazed that I did write down my experience. Here is the post.


72. Edit Distance - 2019 practice

I always like to write C# solution by myself. No matter how good I can understand the dynamic programming, it is always good idea to spend 10 minutes to write a solution.

I thought that I can write a bug free code, but I came cross two bugs. One is missing one problem, I forgot to increment one in first writing and it is caught by online judge. Second one is to play with compiler, and understand the preference of operators.

Here is my discussion post for my last writing.

It is time for me to write a solution using C# and I like to make it bug free, and also it should take me less than 20 minutes.
I just reviewed my two past practice back in 2015 and 2017. To make myself a good problem solver on Edit Distance, I push myself to share and write down some comment first. I also have to learn how to write a C# solution. It does not matter how good I am in dynamic programming, the most important is to train myself to write a solution without any bug.
Here are highlights:
  1. Base case is one of string is empty, or both string are empty;
  2. Empty string is a choice, so distance matrix can be declared using two dimension array with plus one with length of word1 and word2;
  3. Work on three subproblems, I came cross the run time error because I wrote
    var crossValue = cross + left == top? 0 : 1;
  4. Extra on step 3, I extracted one statement called increment variable;
  5. I forgot to increment one on left and top two subproblems case; It is caught by online judge.
  6. Use Array.Min to avoid Math.Min API call. Code is simple to write.
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;

namespace _72_edit_distance
{
    class Program
    {
        static void Main(string[] args)
        {
        }

        /// <summary>
        /// edit distance 72
        /// 2019 July 7
        /// 
        /// </summary>
        /// <param name="word1"></param>
        /// <param name="word2"></param>
        /// <returns></returns>
        public int MinDistance(string word1, string word2)
        {
            if (word1 == null || word2 == null)
                return 0;

            var length1 = word1.Length;
            var length2 = word2.Length;
            if (length1 == 0)
                return length2;
            if (length2 == 0)
                return length1;

            var distance = new int[length1 + 1, length2 + 1];

            // base case: 
            for (int column = 0; column < length2 + 1; column++)
            {
                distance[0, column] = column;
            }

            for (int row = 0; row < length1 + 1; row++)
            {
                distance[row, 0] = row;
            }

            // work on three subproblems - left, top, cross top-left
            for (int row = 1; row < length1 + 1; row++)
            {
                var left = word1[row - 1]; // first one is ""

                for (int col = 1; col < length2 + 1; col++)
                {
                    var top = word2[col - 1];

                    var leftValue = distance[row, col - 1];
                    var topValue = distance[row - 1, col];

                    var cross = distance[row - 1, col - 1];
                    var increment = left == top ? 0 : 1;  // caught by online judge, extract to one statement alone
                    var crossValue = cross + increment;

                    var numbers = new int[] { leftValue + 1, topValue + 1, crossValue };
                    distance[row, col] = numbers.Min();
                }
            }

            return distance[length1, length2];
        }
    }
}

Understand long term bond - BLV

Here is the page for me to study. I like to look into long term bond. Why in 2019 there is over 10% increase?


Case study: Close NYCB bank CD account

July 7, 2019

Introduction


It is my personal finance research. One of my tasks is to close NYCB CD account with 1.2% interest for six years. I need to get my letter notarized by TD bank for free first.

Case study


I will have to think about how to move US dollars to Questrade.com, and then purchase some bond, and wait for bear market coming.


72. Edit Distance - 2017 practice

Here is my discussion post.

It is time for me to review my past practice in 2017. I started to learn how to write advanced feature in c# like var, and I did some work to ask questions on stackexchange.com. I learn how to write and save time to apply implicit typing, for example.
Here are highlights of my practice in 2017.
  1. Understand there are three subproblems to help solve current case;
  2. Based on three options add, delete, replace, the left top cross subproblem can be the same minimum distance or one less;
  3. Base case should be considered first, one of string is empty;
  4. Always remember that empty string with 0 value is also a base case.
public class Solution {
    public int MinDistance(string word1, string word2) {
        int length1 = word1.Length;
            int length2 = word2.Length;

            // consider to add empty space string 
            var distance = new int[length1 + 1][];

            for (int i = 0; i < length1 + 1; i++)
            {
                distance[i] = new int[length2 + 1];
            }

            // base case: one thing is empty, then distance is another string's length  
            for (int i = 0; i < length1 + 1; i++)
            {
                distance[i][0] = i;
            }

            for (int j = 1; j < length2 + 1; j++)
            {
                distance[0][j] = j;
            }

            // recursive,[i][j] depends on left,top and left top 3 situations
            for (int i = 1; i < length1 + 1; i++)
            {
                var current1 = word1[i - 1]; 

                for (int j = 1; j < length2 + 1; j++)
                {
                    var current2 = word2[j - 1];

                    // If last characters of two words are the same, then it is 0. 
                    // If they are different, then it is 1. 
                    var distanceValue = (current1 == current2) ? 0 : 1; 

                    var top     =  distance[i - 1][j];
                    var left    =  distance[i][j - 1];
                    var leftTop =  distance[i - 1][j - 1]; 

                    // from top or from left, both needs insertion
                    var minimum = Math.Min(top + 1, left + 1);    

                    // from top left, consider substitution                                       
                    distance[i][j] = Math.Min(minimum, leftTop + distanceValue);
                }
            }

            // return right bottom corner 
            return distance[length1][length2];
    }
}

72. Edit Distance - 2015 practice

July 7, 2019

Introduction


It is my best favorite thing to do. What it is ?  Read my own code back in 2015. I was shy and also very close a person. Hard working, but I still like to explore more things. At that time, I remember that I ask my retired friend Rick if he likes to purchase a condo in the city of Seattle. I like to go out and drove my Ford Explorer SUV and cross border to shop clothes, hand bags. A lonely person likes to do things and enjoy road trip.  Certainly I do not know that there is a product feature called Discuss, I can share my practice over there, and also learn from other people as well.

My practice 


Today I like to review my practice. For me it is surprise and surprise. I need to review more often, since I learn the dynamic programming solution very well back in 2017 and 2018.

Here is my discussion post I write today.

It is so sweet to read my own code back in 2015. At that time, I started to work on leetcode algorithm, most of times I still google and found blogs written in Chinese, and then read the content I like most; at that time, I did not know there is a product feature called discuss on Leetcode.com. I did not know that there are over hundreds of sharing. I just could not believe that I was the person so close mind; not curious enough to press all possible links on Leetcode.com for a few hours, explore all possible resourceful places.
Lesson No. 1:
Good software programmer should be very curious person.
Another thing is that I should learn that Google search misses a lot of things, all Leetcode discuss will not find in any Google search as well.
All comments are in Chinese, but I will write down the tips for me to score all points in my writing next time.
Here are highlights:
  1. Understand subproblems, there are only three subproblems, from three possible direction, up, left, and cross up left;
  2. Greedy algorithm idea is to find the minimum value in all subproblems, go ahead to calculate three subproblems;
  3. More about step 2, the difficult part is left top cross one. How to determine the minimum value based on the corner? Just replace one char with another one is second string if last char in both string are different;
  4. Ask myself what is maxmimum difference between the current problem and subproblem, since add, delete and replace three choice, the difference is one.
  5. If there is no choice to replace a char, then answer of step 4 question will be 2 for cross corner subprobelm case.
public class Solution {
    public int MinDistance(string word1, string word2) {
        int l1 = word1.Length; 
            int l2 = word2.Length; 

            int[][] distance = new int[l1+1][];
  
            for(int i = 0; i<l1+1;i++)
                distance[i] = new int[l2+1]; 
          
            // 边界情况:当其中一个string为空时,只要一直添加或删除就可以  
            for(int i=0; i< l1+1; i++){  
                distance[i][0] = i;  
            } 
 
            for(int j=1; j< l2+1; j++){  
                distance[0][j] = j;  
            }  
          
            // 递推,[i][j]处可以由左,上,左上3种情况而来  
            for(int i=1; i<l1+1; i++){  
                for(int j=1; j< l2+1; j++){  
                     int tmp = Math.Min(distance[i-1][j]+1,   // 从上演变  
                                        distance[i][j-1]+1); // 从左演变  
                 
                     // 从左上演变,考虑是否需要替换 
                     // avoid word1, word2 index out of range bug - how?
                     // word1: index range from 0->l1-1
                     // word2: index range from 0->l2-1
                     // but distance[i][j] is between word1's substring from 0 to i-1 and word2's substring from i to j-1
                     // there is one difference! 
                     distance[i][j] = Math.Min(tmp, distance[i-1][j-1]+((word1[i-1]==word2[j-1]) ? 0 : 1));                  
                }  
            }  

            // 返回右下角
            return distance[l1][l2];  
    }
}






My weight loss journey

July 7, 2019

Introduction


It is time for me to work on weight loss project in Summer time. I like to have more unprocessed food, and also take more walks in day time, and enjoy sports.


My weight loss journey


I start to weight myself once a day. I like to plan some good workout for myself as well.


What if I fail Fortinet onsite in July 2019

What if I fail Facebook phone screen in July 2019?

What if I fail Amazon phone screen in July 2019?

July 8, 2019

Introduction


It is now 12:09 AM. I like to go to sleep, but this blog is my home work. I like to write down some thoughts and explain to myself how good I can be in my career.

What if I fail


I need to find time to learn how to do a good job in terms of object-oriented design, system design. I love to write code every day, algorithm and data structure.

If I fail the phone screen, I should start to work on more as an interviewee, not interviewer all the time.

It is also a good idea to solve another 100 to 200 algorithm on Leetcode.com.

I should pay attention to test my own code after I wrote the code. I find out that I miss white board testing after I practice.

MONETARY POLICY INTEREST RATES Interest Rate Risk Between Long-Term and Short-Term Bonds

Here is the link.


Two low-fee Canadian bond ETFs a good way to hold bonds today

Here is the link.


Vanguard Canadian Long-Term Bond Index ETF

Here is the link.

I like to purchase some long term bond.




Saturday, July 6, 2019

Fortinet onsite

July 6, 2019

Introduction


I will have my first Fortinet onsite in the city of Vancouver last 9 years. I am nervous even though I know so many engineers working there.

Fortinet 


I always pass by Fortinet building but I never have chance to visit the office in Burnaby. I always visit Microsoft office and Amazon office in the down town. This will be my first visit, no phone screen. I just could not believe that I can get invitation on this opportunity.




What if I can pass Amazon phone screen in 2019 July?

July 6, 2019

Introduction


It is my personal finance research. I am preparing for Amazon phone screen. As a software programmer, I like to code every day. Of course, I love to go through the preparation, and also blog about my experience. What if i can pass Amazon phone screen in 2019 July.

Short research


I had a conversation with my young sister this weekend. She said if I did not get a job offer from 2016 after the first onsite, why I still continue to try second onsite interview. I do believe that my job is to solve problem by writing software. I like to work on algorithm and data structure every day. It is so pleasant to meet another engineer, and have a short conversation through the phone screen.

That is my job as a software engineer, good engineer should love to meet people, and demonstrate good problem solving skills to the world.

My Amazon phone screens


I had one Amazon phone screen in May 2018, and also one in January 2017, one in May 2016.

I will have a phone screen from Seattle Amazon AWS team. The engineer also worked for Microsoft before. I am surprised that I will have challenge job to do to prove that I am worthy for another onsite interview.

In 2016 the phone interviewer is a young graduate. In January, 2017, the interviewer is a young engineer and I failed the phone screen.

In 2019 the phone interviewer has more than a few years in Microsoft, and now has more than a few years in Amazon AWS team Seattle as well.

My role model


I met an engineer who has more than 10 years experience less than two weeks ago, I asked him to solve lowest common ancestor algorithm. He is senior lead, worked for Microsoft before. I just remembered the conversation we had. I said that you will pass the phone screen since you work hard, and test your own code; I will fail as an interviewer, since I memorize the answer, I wrote a line of code with a bug, and interviewee went through the test case and found it.

So the interviewee demonstrated how serious he is in mock interview. He went through the test case and line by line test the code.





What if I can pass a phone screen from Facebook in 2019?

July 6, 2019

Introduction


It is my personal finance research. I do not expect that I will have a phone screen from Facebook again this July after I failed one in August 2018. I just work hard to push myself to advance my problem solving skills. I did learn so much through the phone screen back in August 2018.

What if?


I do believe that it is so much easy for me to work on algorithm and data structure problem daily. I have built a good habit to write a few algorithms, even though I write more than once, or more than 10 times on an algorithm. I know that there is a new problem to come out or I should look into.

2018 phone screen


I did find my biggest problem after 2018 phone screen with Facebook. I noticed that I will have problem to handle stress, I act impulsively instead of being cool, applying some analytical skills. I should make myself easy to work with and be super emotional supporting the interviewer doing good assessment job.

I am getting better


I went through so many mock interviews as an interviewer on interviewing.io after August 2018. I got complaint in and after the interview, and got two times interviewee telling me to quit since anxiety.

I learn that I should help interviewee to learn better through mock interview, make it a pleasant learning experience.


I am better learner


I am a better learner. I can work on tree algorithm every week day if interviewee keeps the interview or show up. I just choose to ask a tree algorithm lowest common ancestor. The idea to use the same algorithm is to help me figure out who is best talent in the world through those interviewees.

I am so humble since I learn that it is so important for me to work on algorithm problem solving, and also demonstrate very good attitude to learn and make the problem solving experience more meaningful in phone screen.



What if I can get a job from Facebook in 2019?

July 6, 2019

Introduction


It is my personal finance research. I like to write on a small research topic, what if I can get a job from Facebook in California in 2019.


Small research


I learn the fact that in order to be successful in my career, I have to push myself hard. One thing is to keep applying Facebook jobs every year.

I like to push myself to work hard, specially on algorithm and data structure. I enjoy a work day better with one or two solution I can write just to test how fast I can write, how clearly I can put together an idea into C# code.

So many beautiful memory with Facebook downtown office in the city of Vancouver, people I met and also a lot of good experience with the company.

What if I can get a job in 2019?


It is so difficult for me in 2019 to push myself to advance my Leetcode weekly contest. I have to manage my performance in 90 minutes and have to work on three algorithms.

If I can easily manage myself to advance to top 3000 ranking, then I should not have problem to handle phone screen or onsite algorithm problem solving.

I still need to work on a few areas in terms of problem solving.

To get a job from Facebook, it is much hard to compare to other companies. I should have learned so much in order to be able to get an onsite interview invitation.

My motivation to get a job


I like to build wealth and enjoy life as a software programmer.




Get smart, get financial fit for basic needs

July 6, 2019

Introduction


It is my personal finance research. I went to visit an open house near King George skytrain station. The one bedroom condo is selling $288,000 dollars, and another unit same size is selling $399,000 Canadian dollars.

Case study


I learn that market price is so interesting and one owner just needs to sell as soon as possible. He does not like to wait a few months to get an offer.

I still cannot afford the place. The stress test does not allow me to borrow five time of my salary, I do not have over $100,000 dollars for the down payment.

I really do not like to live a condo isolated from neighbors. 26th floor, you cannot go to another floor since every floor needs the key to access.

The home address is 13696 100 Ave Surrey BC - Asking price $288,000.