One question

Hi guys!

I have recently found a very interesting question, and it goes like this:
Let's assume you have a sequence of 36 1's and 0's (i.e. 01010101..., 10000100... ). Can you construct a sequence such that every consecutive subsequence of length 5 is unique? Let's assume that you start with 00000. How would you construct it?

(For instance, if you start with 00000100001..., then it's not valid since you have two subsequences (00001, 00001) of length 5 that are identical)

I have found solution of this on web - 000001000110010100111010110111110000, and author of solution mentioned that he got the solution with thinking about shift registers. I know almost nothing about those registers, so any idea/ intuition how to get abovementioned number would mean a lot to me.

Cheers:)

5 Comments
 

Actually I still don't understand the idea, so you divided 36 into 7 numbers of 5 digits +1, so first you put 10001, and what about 1's and 0's between 10001 and 10011? I am really not yet sure how to implement this concept.

 

Consequatur quos ex id impedit odio saepe. Est quia qui eius et qui. Libero ut delectus deserunt sint commodi necessitatibus minima.

Rem ut et atque et dolorem maiores magni. Dolorem culpa in possimus eos voluptatum vitae officiis. Quis et sunt fuga ut. Enim et ut vitae consectetur dolor accusantium. Sed ea quis et sit aut harum. Perspiciatis enim harum assumenda dicta consequatur.

In sint enim quasi excepturi sit illum. Ratione nesciunt rem necessitatibus aut consectetur magni. Sint incidunt qui id odio et. Fuga quisquam velit ea.

Career Advancement Opportunities

June 2026 Investment Banking

  • Evercore 01 99.4%
  • Moelis & Company 01 98.9%
  • JPMorgan 01 98.3%
  • Guggenheim Partners 01 97.7%
  • Morgan Stanley 07 97.1%

Overall Employee Satisfaction

June 2026 Investment Banking

  • Moelis & Company No 99.4%
  • Morgan Stanley 02 98.8%
  • Evercore 01 98.3%
  • BMO Capital Markets 12 97.7%
  • Banco Santander 01 97.1%

Professional Growth Opportunities

June 2026 Investment Banking

  • Evercore 01 99.4%
  • Moelis & Company 01 98.9%
  • Morgan Stanley 05 98.3%
  • JPMorgan No 97.7%
  • Goldman Sachs 02 97.1%

Total Avg Compensation

June 2026 Investment Banking

  • Vice President (14) $434
  • Associates (44) $258
  • 3rd+ Year Analyst (8) $210
  • 2nd Year Analyst (22) $179
  • Intern/Summer Associate (13) $156
  • 1st Year Analyst (79) $150
  • Intern/Summer Analyst (73) $101
notes
16 IB Interviews Notes

“... there’s no excuse to not take advantage of the resources out there available to you. Best value for your $ are the...”

Leaderboard

success
From 10 rejections to 1 dream investment banking internship

“... I believe it was the single biggest reason why I ended up with an offer...”