Thursday, May 30, 2019

Case study: January 31, 2019 mock interview and algorithms

May 30, 2019

Introduction


It is time for me to review one of my mock interviews since I found one of Linkedin connections joined Facebook recently. I like to review the mock interview I had with the engineer this January 31, 2019.

Case study




Wednesday, May 29, 2019

Case study: Immigration department letter about permanent resident card photo

May 29, 2019

Introduction

It is my personal finance research. I like to write a case study about my nephew immigration process, this morning I got an email that the photo does not meet permanent resident card requirement. He landed in May 15, and went back to China in May 19. Today is May 29, 2019, I got ...

Top Performing Information Technology ETFs of 2018

Here is the link.


Should I use robo advisor Essential portfolio on Ameritrade.com?

May 29, 2019

Introduction


It is my personal finance research. I like to learn how to hold growth fund and learn how to rebalance every quarter if need. One idea is to open an account and put $5,000 US dollars of my IRA and let Robo advisor to do the work.

Case study


I like to learn how to do rebalance the portfolio and understand the market, my time horizon, and risk tolerance and my finance goal. One of ideas is to open an account on Essential portfolio on Ameritrade.com.


Best ETFs: Sector Funds

Here is the link.

Real estate
SCHHSchwab US REIT ETF*112A4.1
USRTiShares Core US REIT*112B0.5
FRELFidelity MSCI Real Estate161C0.4
VNQVanguard Real Estate194A+30.2
XLREReal Estate Select Sector SPDR213A2.3
RWRSPDR Dow Jones REIT402A2.4
ICFiShares Cohen & Steers REIT532A2.5
KBWYInvesco KBW Premium Yld Eq REIT577B0.4
WREIWilshire US REIT620F0.01
EWREInvesco S&P 500 Eql Wt Rl Estt664D0.02

Technology
FTECFidelity MSCI Information Tech*142A1.9
VGTVanguard Information Technology*147A19.2
XLKTechnology Select Sector SPDR210A+20.4
PSCTInvesco S&P SmallCap Info Tech378C0.4
XSDSPDR S&P Semiconductor384B0.3
IGNiShares North American Tech-Multimedia Networking467C0.1
XWEBSPDR S&P Internet E484F0.01
XNTKSPDR NYSE Technology514B0.9
SMHVanEck Vectors Semiconductor563A+1.4
XSWSPDR S&P Software & Services570D0.1
RYTInvesco S&P 500 Eql Wt Tech647B1.7
XITKSPDR FactSet Innovative Tech651D0.02
XTiShares Exponential Technologies664B2.3
Oil & gas
FENYFidelity MSCI Energy*146B0.6
VDEVanguard Energy151A4.3
XESSPDR S&P Oil & Gas Equipment&Svcs177B0.4
XLEEnergy Select Sector SPDR203A+18.6
XOPSPDR S&P Oil & Gas Explor & Prodtn434A2.8
IEZiShares U.S. Oil Equipment & Services470B0.2
PSCEInvesco S&P SmallCap Energy491D0.1
OIHVanEck Vectors Oil Services567A1.7
RYEInvesco S&P 500 Eql Wt Energy660B0.2
FILLiShares MSCI Global Energy Producers683F0.04
Medical
PBEInvesco Dynamic Biotechnology & Genome-879C0.2
XBISPDR S&P Biotech112A4.7
VHTVanguard Health Care144A7.0
FHLCFidelity MSCI Health Care145B1.1
XPHSPDR S&P Pharmaceuticals174B0.3
XLVHealth Care Select Sector SPDR212A+14.7
IHEiShares U.S. Pharmaceuticals292B0.4
PSCHInvesco S&P SmallCap Health Care397C0.5
XHESPDR S&P Health Care Equipment561C0.3
IBBiShares Nasdaq Biotechnology562A8.9
PPHVanEck Vectors Pharmaceutical569B0.2
BBHVanEck Vectors Biotech575B0.4
XHSSPDR S&P Health Care Services579D0.1
HCRFiShares Edge MSCI Multifactor HlthC610F0.01
RYHInvesco S&P 500 Equal Wt HC649B0.6
Industrials
FIDUFidelity MSCI Industrials*146B0.5
VISVanguard Industrials168B3.5
XLIIndustrial Select Sector SPDR210A+12.1
PSCIInvesco S&P SmallCap Industrials518D0.1
XTNSPDR S&P Transportation544B0.2
XARSPDR S&P Aerospace & Defense544B1.3
ITAiShares U.S. Aerospace & Defense652A5.9

Tuesday, May 28, 2019

Case study: My portfolio

May 28, 2019

Introduction


It is time for me to come out the portfolio of IRA Ameritrade account. I have around $16,000 US dollars right now, I just bought BND ETF two weeks ago, I need to figure out how to set up a portfolio for long term growth.

Case study


I like to work on $12,000 fund and plan to purchase VTI, VYM, VGT, VUG four ETF.
VTI 20 shares x 143
VYM  $84.13 * 40
VUG 
VGT   $197.81 x 20

Case study: Mock interview on lowest common ancestor

May 28, 2019

Introduction


I had a mock interview 10:00 PM today. I asked the interviewee to work on the algorithm called lowest common ancestor, and it turns out that he is super good engineer and very good problem solver.

Case study


The interviewee just showed me how good he was to solve the problem, and also worked on extended problem.

I will add more content here later.

Interviewee feedback


Interviewer feedback


Actionable Items


What I do is to share my learning on Leetcode.com.
C# recursive function to find lowest common ancestor given p and q are in the binary tree (May 28, 2019)
C# recursive function to find lowest common ancestor given p and q (May 28, 2019)

Best Canadian ETFs for 2019

Here is the link.

Best Canadian ETFs – The list


ETF nameTickerManagement FeeMER# of HoldingsDescription
Vanguard FTSE Canada All Cap Index ETFVCN0.050.06212Exposure to Canadian small, medium and large caps, ultra low fee
iShares Core S&P/TSX Capped Composite Index ETFXIC0.050.06250Tracks Canada's best known index with a very low fee
Horizons S&P/TSX 60 ETFHXT0.030.0360Tax-efficient
BMO S&P TSX Capped Composite IDX ETFZCN0.050.06251Fee as low as VCN and XIC; more assets than VCN

2019 April algorithm practice

2019 - April 
4/29
1035. Uncrossed Lines C# dynamic programming solution readable code
1034. Coloring A Border C# using two negative values to mark visited, -1 for the mark to change color
1033. Moving Stones Until Consecutive Ever tried. Ever failed. No matter. Try again
4/23
957. Prison Cells After N Days C# First practice in April 2019
4/22
75. Sort Colors C# Work on test case [2, 0, 1, 2] and then figure out the idea
1031. Maximum Sum of Two Non-Overlapping Subarrays Need to shorten the time
402. Remove K Digits C# easy to write using stack with analysis
402. Remove K Digits C# brute force solution - time consuming and struggling
4/15
1026. Maximum Difference Between Node and Ancestor code written in weekly contest
1025. Divisor Game C# recursive function practice after the weekly contest
1025. Divisor Game dynamic programming solution - Attention Please!
4/10
1024. Video Stitching C# greedy algorithm only one iteration on sorted array
4/18
1023. Camelcase Matching written in the contest 131
1023. Camelcase Matching solution learned after the contest
1022. Sum of Root To Leaf Binary Numbers C# a recursive function with module calculation
1021. Remove Outermost Parentheses
4/2
947. Most Stones Removed with Same Row or Column C# Use partial of union find algorithm to solve the problem
947. Most Stones Removed with Same Row or Column C# apply depth first search in a graph
947. Most Stones Removed with Same Row or Column weekly contest ranking 5, 8, 12, 13, 16, 40, 58, 117, 176 players - code study
947. Most Stones Removed with Same Row or Column union find algorithm study - rank, size, path compression, common mistakes, while/ recursive implementation
200. Number of Islands C# depth first search practice