Entrepreneur Stuff


9 years after starting my first biz in my mom’s basement, and 4 companies later – these are my biggest takeaways so far… from Entrepreneur

After raising over $360,000 on Indiegogo and creating a 7-figure business in less than 1 year – this is everything I learned about crowdfunding. from Entrepreneur

EMSK: Doors don’t close anywhere near as often as you think. from everymanshouldknow

What the Hell is Linux?

Alright. Here we go! I’ve done some itty bitty research and will shortly forget what Linux is all about cuz I vaguely remember searching the same info before. So yeah! Let’s Start!

Unix: Initially, it was a AT&T built operating system. Now, It’s a family of operating systems that derive from it, like

  • BSD/Berkeley Software Distribution (386BSD (FreeBSD, NetBSD…), Darwin (macOS, iOS), SunOS))
  • GNU
  • Linux (Android, Chrome OS)
  • QNX (BlackBerry 10)

Based on its design, Unix like operating systems have come to exist. Most Famous: Linux.

Linux releases a new version of their “kernel” every now and then. And due to the flexibility, customizability, free and open-source nature of Linux, it becomes possible to highly tune Linux for a specific purpose or just make a general purpose version. There are different foundations/groups who pick up the kernel release, modify it and package it along with a bunch of mostly free (called GNU stuff) or paid software in a form known as a Linux distribution (or distro for short) for both desktop and server use. You cannot use Linux without a distro since Linux by itself is just a kernel. Read more here.

Linux Distribution timeline 2016
Linux Distribution timeline 2016. Btw, the image is Ctrl + F able.

General purpose Linux distributions: Some of the most popular are Debian, Fedora, Ubuntu (which is itself based on Debian) together with commercial distributions such as Red Hat Enterprise Linux.

Specialized Linux distribution: There are two main methods for creating them: building from scratch (i.e. Pure Linux) or from a general-purpose distribution as a base. Linux distributions built from scratch do not have general-purpose bases; instead, they focus on the JeOS philosophy by including only necessary components and avoiding resource overhead caused by components considered redundant in the distribution’s use cases. Eg of Specialized distros: Kali Linux for digital security (Based on Debian).

Packages: Each distro, while they may be based off of one another need to be “binary compatible” to allow packages (or softwares/apps) from one distro to be used in another. So care for that must be taken.

What rights do I have if I have been arrested by the police in India?

What rights do I have if I have been arrested by the police in India? by Tejasvita Apte

Answer by Tejasvita Apte:

The first thing you need to know is –

Every person who is arrested is supposed to be taken before the nearest magistrate within 24 hours of the arrest. (Time taken to travel to the Magistrate is excluded from the 24 hours)

This is the most important thing you need to know.

You then have the following rights –

1. Right to be silent / Right against self – incrimination

You have the right to remain silent. In fact the police is supposed to tell you that everything you say may be used against you in the court of law.

Regardless of whether they tell you this or not, remember you have the right to remain silent.

2. You have the right to legal aid-

You have the right to call your lawyer. If you ever get a call from a Police station and they ask you to come and answer some questions, even then, first contact your lawyer. Do not walk into the station. You can ask the police officer to summon you in writing.

3. If there is a warrant, you are entitled to see it –

Remember you can be arrested even without a warrant. But if the Police say that they have a warrant, you have a right to see it.

4. Right against Handcuffing and torture

You have a right to not be handcuffed. Only if the police suspect that you are likely to run away, should they handcuff you.
You cannot be subjected to torture and it is a crime.

5. Right to have someone informed

If you are arrested without anyone's knowledge or presence, you have a right to inform someone. The law puts an obligation on the law enforcement agency to inform another person.

6. You cannot be illegally detained –

If you are being detained by the Police and are not produced before the Magistrate within 24 hours, it is illegal. You (you friend / relative) have the right to directly approach the High Court and file the writ of Habeas Corpus.

7. If you are a woman, you cannot be arrested after sundown and before sunrise unless there are extraneous circumstances. If there are, Magistrate's written permission and the presence of a woman police officer is required to make that arrest.

Some other useful important points –

1. After detention, you are the responsibility of the Police. Remember that. If you think that procedure is not followed, be mindful and make mental notes of everything around you. Names and designations of officers, etc.

2. The Police officers cannot do anything they want with you. They are bound by law. Co-operate if it is not going to incriminate you.

3. Do not resist an arrest and try to run. You cannot. If you are being arrested, be mindful and assert your rights. Let them know, you know.

4. If someone you know is detained but you don't know where, you can file an RTI application in the Police station you suspect and they are bound by law to give you information within 48 hours as to the whereabouts of your friend.

5. Sometimes people are arrested on Friday/ Saturday and kept in custody till Monday morning with the claim that Magistrate isn't available. That is not true. A magistrate is available 24*7. Know that.

6. The Police officer cannot force you to make a confession. Confessions made to Police officers are inadmissible in evidence.

7. If you are arrested for a Bailable offence, you can get bail from Police itself. If you are arrested for a Non-bailable offence, only the court can grant you bail. If you get a bail, it doesn't mean the trial is over.

(Bailable offences are less serious offences in which bail is a right. In such cases you must get bail immediately from the police. Non-bailable offences are serious offences where bail is a privilege and only the courts can grant it.)

8. If you anticipate being arrested, you can move the court and take an anticipatory bail.

9. Unlike, what is normally believed, a traffic police officer can also arrest you. He is also a Police officer who has just been given traffic duties.

Thank you for the ATA, Himel Sarkar.

If you found this answer informative, you can follow my blog about Indian laws – Blawgniti.

What rights do I have if I have been arrested by the police in India?

DIGIT Magazines

Stable Web archive version: Here.

Beyond this, any backed up version of this page on web archive will appear broken. Actually, the links still work but it’ll take you an extra click. So if you’re currently viewing this page on web archive, go to the above linked url for best experience.


2001

200106_digit 200107_digit 200108_digit 200109_digit 200110_digit 200111_digit 200112_digit


2002

200201_digit 200202_digit 200203_digit 200204_digit 200205_digit 200206_digit 200207_digit 200208_digit 200209_digit 200210_digit 200211_digit 200212_digit


2003

200301_digit 200302_digit 200303_digit 200304_digit 200305_digit 200306_digit 200307_digit 200308_digit 200309_digit 200310_digit 200311_digit 200312_digit
Hosted on archive.org: 200307


2004

200401_digit 200402_digit 200403_digit 200404_digit 200405_digit 200406_digit 200407_digit 200408_digit 200409_digit 200410_digit 200411_digit 200412_digit


2005 (start converting links here)

200501_digit 200502_digit 200503_digit 200504_digit 200505_digit 200506_digit 200507_digit 200508_digit 200509_digit 200510_digit 200511_digit 200512_digit


2006

200601_digit 200602_digit 200603_digit 200604_digit 200605_digit 200606_digit 200607_digit 200608_digit 200609_digit 200610_digit 200611_digit 200612_digit


2007

200701_digit 200702_digit 200703_digit 200704_digit 200705_digit 200706_digit 200707_digit 200708_digit 200709_digit 200710_digit 200711_digit 200712_digit


2008

200801_digit 200802_digit 200803_digit 200804_digit 200805_digit 200806_digit 200807_digit 200808_digit 200809_digit 200810_digit 200811_digit 200812_digit


2009

200901_digit 200902_digit 200903_digit 200904_digit 200905_digit 200906_digit 200907_digit 200908_digit 200909_digit 200910_digit 200911_digit 200912_digit
Hosted on archive.org: 200904, 200912


2010

201001_digit 201002_digit 201003_digit 201004_digit 201005_digit 201006_digit 201007_digit 201008_digit 201009_digit 201010_digit 201011_digit 201012_digit
Hosted on archive.org: 201006, 201007, 201012


2011

201101_digit 201102_digit 201103_digit 201104_digit 201105_digit 201106_digit_1
201106_digit_2 201107_digit 201108_digit 201109_digit 201110_digit 201111_digit 201112_digit
Hosted on archive.org: 201101, 201104, 201111


2012

201201_digit 201202_digit 201203_digit 201204_digit 201205_digit 201206_digit 201207_digit 201208_digit 201209_digit 201210_digit 201211_digit 201212_digit
Hosted on archive.org: 201205, 201206, 201207, 201208


2013

201301_digit 201302_digit 201303_digit 201304_digit 201305_digit 201306_digit 201307_digit 201308_digit 201309_digit 201310_digit 201311_digit 201312_digit


2014

201401_digit 201402_digit 201403_digit 201404_digit 201405_digit


Archive.org Hosted file page: https://archive.org/details/digitPDFover32mb

What’s with 32 bit systems supporting max 4GB of RAM?

So you know that RAMs contain storage space. Common sense. Every byte of memory on RAM requires to have an address allocated to it. A 32-bit machine uses 32 bits long address to designate each byte of memory. And a memory that does not have an address allocated can not be seen by the machine.

Now let’s understand how these addresses work.

Each bit has a value of 0 or 1. If you have 1 bit long address, you have two possible addresses: 0 or 1. A two-bit system has four possible address: 00 =0, 01=1, 10=2, 11=3. 2^2=4. Three bits have 8 possible addresses: 000=0, 001=1, 010=2, 011=3, 100=4, 101=5, 110=6, and 111=7.

Each bit doubles the potential address space, which is why 2^n tells you how many addresses you use for a given number of bits. 2^1 = 2, 2^2 = 2*2 = 4, 2^3 = 2*2*2 = 8, etc. By the time you get to 32 bits, you have allocated address to 2^32 = 4294967296 bytes of RAM space which is equal to 4GB.

(((2^32bytes/2^10)KB)/2^10)MB)/2^10)GB = 2^2GB

Okay, so if the processor, and the operating system designed for that processor, can only handle 4GB, why can’t your PC (if it’s 32-bit) see that much practically?

Because not all of those addresses are available for RAM. There are other pieces of hardware inside your computer that need addresses, such as the PCI bus and the USB host adapter, Graphics card, etc.


Whenever you store something in the memory, you need to save the address to be able to read or manipulate it. Usually, the CPU uses only one register (32 bit in size) to store this address. Since there are only 2^32 different addresses, anything exceeding the 4GB mark remains unused.

However, there are techniques like Physical Address Extension (PAE) that allow a 32-bit OS to address more than 4GB of RAM.


Source of some info, More Source

What is the best strategy to improve my skills in competitive programming in 2-3 months?

Answer by Sachin Gupta:

This post has been taken from the blog post  Learn to Code by Competitive Programming written by MV Kaushik when he was interning at HackerEarth

Here are some steps to get started and be good at it.

    • Get comfortable writing code in either of one of these languages C, C++ or Java. Why only C, C++ or Java? Because these are the standard languages allowed in any programming competition.
    • If you are already good at C, it is suggested to learn C++. It is the most popular language among competitive programmers because of its speed and an excellent library in the form of STL (Standard Template Library).
    • Pick an online judge. Recommended ones are Topcoder and Codeforces. These sites have high quality of problems and also allow you to see other’s code post contest completion. These also categorize problems based on the topic. Some other popular judges include SPOJ, CodeChef (powered by SPOJ) andHackerEarth.
    • To begin with, start with simple problems that typically require transformingEnglish to code and does not require any knowledge on algorithms. Solving Div 2 250 (Division 2, 250 points) in Topcoder or Div 2 Problem A in Codeforces is a good start.
    • At the early stages of programming one tends to write long pieces of code, which is actually not required. Try to keep codes short and simple.
    • Practice these problems until you become comfortable that you can submit it for 240 odd points on any day.
    • Start implementing basic(or standard) algorithms. It is suggested to read them from Topcoder tutorials or Introduction to algorithms.

      1) Graph algorithms: Breadth first search(BFS), Depth first search(DFS), Strongly connected components(SCC), Dijkstra, Floyd-Warshall, Minimum spanning tree(MST), Topological sort.

      2) Dynamic programming: Standard dynamic programming problems such as Rod Cutting, Knapsack, Matrix chain multiplication etc.

      3) Number theory: Modular arithmetic, Fermat’s theorem, Chinese remainder theorem(CRT), Euclidian method for GCD, Logarithmic
      Exponentiation, Sieve of Eratosthenes, Euler’s totient function.

      3) Greedy:  Standard problems such as Activity selection.

      4) Search techniques: Binary search, Ternary search and Meet in the middle.

      5) Data structures (Basic): Stacks, Queues, Trees and Heaps.

      6) Data structures (Advanced): Trie, Segment trees, Fenwick tree or Binary indexed tree(BIT), Disjoint data structures.

      7) Strings: Knuth Morris Pratt(KMP), Z algorithm, Suffix arrays/Suffix trees. These are bit advanced algorithms.

      8) Computational geometry: Graham-Scan for convex hull, Line sweep.

      9) Game theory: Basic principles of Nim game, Grundy numbers, Sprague-Grundy theorem.

      The list is not complete but these are the ones that you encounter very frequently in the contests. There are other algorithms but are required very rarely in the contests.

    • You can find description and implementation of standard algorithms here
    • Once you have sufficient knowledge of popular algorithms, you can start solving the medium level problems. That is Div 2 all problems in Topcoder and Codeforces. It is advisable not to go for Div 1 500 at this point.
    • Learning to code is all about practicing. Participate regularly in the programming contests. Solve the ones that you cannot solve in the contest, after the contest. Apart from Topcoder and Codeforces you can also look at HackerEarth Challengesor Codechef contests.
    • Read the codes of high rated programmers. Compare your solution with them. You can observe that it is simple and shorter than your solution. Analyse how they have approached and improve your implementation skills.
    • Read the editorials after the contest. You can learn how to solve the problems that you were not able to solve in the contest and learn alternative ways to solve the problems which you could solve.
    • Always practice the problems that you could solve in the contest. Suppose if you are able to solve Div 2 250 and 500 in the contest but not Div 2 1000 then practice as many Div 2 1000 problems as as you can.
    • Do not spend too much time if you are not getting the solution or are stuck somewhere.
    • After you feel that you have spent enough time, look at the editorials. Understand the algorithm and code it. Do not look at the actual solution before you have attempted to write the code on your own.
    • Programming is a very practical and hands on skill. You have to continuously do it to be good at it. It’s not enough to solve the problem theoretically, you have to code it and get the solution accepted. Knowing which algorithm/logic to use and implementing it are two different things. It takes both to be good at programming.
    • Programming learning phase is going to take a lot of time and the key is practicing regularly. It takes some time before you can attempt Div 1 500 and other tough problems. Do not give up on reading the editorials and implementing them, even if it takes many hours/days. Remember everything requires practice to master it.

It takes considerable amount of time before you get good at it. You have to keep yourself motivated throughout. Forming a team and practicing is a good choice. Not giving up is the key here.

What is the best strategy to improve my skills in competitive programming in 2-3 months?

What was Anudeep Nekkanti’s Competitive Programming strategy to become 35th in Global ranking, in just 6-7 months?

Answer by Anudeep Nekkanti:

What I did ?

Result ?

  • Became very good with C++ and STL
  • Got introduced to most Competitive programming KEYWORDS (like DP, maxflow, sets, hashing, etc)
  • Learned Standard Problems and Algorithms
  • Indenting code
  • Fast typing 😛

How ?
Before starting programming, I searched about how and where to start, many said “Learn an Algorithm, implement it, solve  problems related to it”. I did not do it that way, If you know what algorithm to use you generally think in that direction and leave about correctness.  I did them problem by problem, easy to hard, I spent 1 – 4 hours on a problem.
I get the idea, I code it, Get it Accepted. (I used to test a lot, I always wanted to get AC on first go)

I do not get the idea, I save that problem and try it after a month again. If I still do not get them, then search for hints. If it clearly needed some algorithm which I never used then I first smile (? I could not only because I did not knew the algorithm 😛 ) and then start reading about that algorithm. TopCoder had tutorials of almost all common algorithms. This is where I did a BIG MISTAKE. I never cared about correctness or run-time analysis proof, I always learned how to solve the problem using that algorithm, I hardly learned about how the algorithm works. I feel bad about it now, but that is how I solved those problems then. I solved max-flow, convex hull, etc., problems using described algorithms but I did not UNDERSTAND those algorithms then.

Mistake: Once I started taking part in contests, I completely stopped practice.

35th in Global Ranking

  • CodeChef long contests are comparatively easy ( Which is good, You can learn a lot), you get a lot of time to think about a problem, search for resources. You only need KEYWORDS to search for similar problems.
  • I gave a lot of time for each contest. I used to solve 4 easy problems in 2-3 days, then take 5-6 days for other 3 problems.
  • CodeChef rating system is not good. It is highly Volatile.

If I am to start programming now, I would do it this way

  1. Solve 200 most solved problems on SPOJ, Problem by problem. In 2 months.
    (This will teach all standard problems, algorithms and implementation skills)
  2. Solve problems from CodeChef and CodeForces for 2 months.
    (This will teach variations, we can read others solutions and learn better ways. Skip easy problems)
  3. Solve problems from TopCoder for 2 months.
    (This will teach  Dynamic Programming. Div 1 500p)
  4. Check past ACM ICPC Regional’s Problems
    (Great quality problems)

If I am to learn a new Algorithm now, I would do it this way

  1. Read it from at least 3-4 different sources.
  2. Understand correctness proof and run-time analysis.
    (This is very very important, you will know it only when you  deal with non standard  and hard problems)
  3. Question yourself on every step for correctness. Try to tweak the implementation.
  4. Check other implementations.

Final Note
Thought I became good in solving problems and had good rank. I later(Feb 13) realized that I learned it the wrong way. I then started learning again. I learned all the algorithms again this time gave importance to the algorithm itself, correctness proof and mathematical analysis. It is worth the time.

Lucy and the Flowers – Problem from December long contest, Try to solve it with suffix arrays. You can only if you understand suffix arrays and LCP completely.

I was able to solve a not-so-obvious medium level Max-Flow problem at ACM KGP Onsite only because I completely understood how the algorithm works. It was at 4 hour 25 minutes I got 5th problem accepted, then I read this problem and got it accepted 4 minutes before end. Learning the algorithm helped. Dot.


What was Anudeep Nekkanti’s Competitive Programming strategy to become 35th in Global ranking, in just 6-7 months?

Why does breaking the sound barrier create a sonic boom?

Boom is really a misleading word for it because it implies something like an explosion – when really it’s more of a constant roar. It just sounds like a boom from land, because unlike normal sound, which would reach you from the plane constantly as it flies by, the boom is like the wake of a boat, only hitting you once for each pass.

I think part of the reason this isn’t well known is because of all the photos of jets breaking the sound barrier.

http://res.cloudinary.com/dk-find-out/image/upload/q_80,w_1440/A-iStock_000017498245Large_pxojdi.jpg

That plane wasn’t going supersonic though. The cone happens at transonic speeds, so when the plane is accelerating, as it nears Mach 1 a shock cone can appear. You can tell in the video that it is very close to Mach 1 because there is no sonic boom and the sound from the plane appears just before it passes.