The execute permission bit for a directory is often called the search bit, because if you want to open a file by name, you need to have execute permission in each directory in the pathname, e.g. /home/username
This is different from read permission: list content of a directory
This is different from read permission: list content of a directory
Similar GCP/AWS services
- Compute Engine ~ Elastic Compute Cloud
- Kubernetes Engine ~ Elastic Kubernetes/Container Service
- App Engine ~ Elastic Beanstalk
- Cloud Functions ~ Lambdas
- Compute Engine ~ Elastic Compute Cloud
- Kubernetes Engine ~ Elastic Kubernetes/Container Service
- App Engine ~ Elastic Beanstalk
- Cloud Functions ~ Lambdas
Check if there's a root-to-leaf path such that the sum of all the along the path equals a given sum.
bool f(Node* r, int sum) {
if(!r) return false;
if(!r->left && !r->right && sum == r->val) return true;
return f(r->left, sum - r->val) || f(r->right, sum - r->val);
}
bool f(Node* r, int sum) {
if(!r) return false;
if(!r->left && !r->right && sum == r->val) return true;
return f(r->left, sum - r->val) || f(r->right, sum - r->val);
}
Resume tip for junior devs:
Don't put junior on your CV/portfolio.
Let them decide where you fit based on your skills.
Don't put junior on your CV/portfolio.
Let them decide where you fit based on your skills.
Radix sort is an algorithm that sorts numbers by processing individual digits.
The best architectures, requirements, and designs emerge from self-organizing teams
agilemanifesto .org
agilemanifesto .org
The expected constant time property of a hash table assumes that the load factor be kept below a certain bound.
Difference between x86, i386 and x64:
- x86 is a family of instruction set architectures based on Intel 8086
- i386 or x86-32 is the 32-bit architecture of the x86 family
- x64 is the 64-bit instruction set of the x86 family. Also called amd64, designed by AMD
- x86 is a family of instruction set architectures based on Intel 8086
- i386 or x86-32 is the 32-bit architecture of the x86 family
- x64 is the 64-bit instruction set of the x86 family. Also called amd64, designed by AMD
You can use hash tables to avoid creating multiple immutable data structures with the same content.
A project's bus factor is the number of team members who would put the project in jeopardy if run over by a bus (or get sick, vacation, resign, ...)
Strive to increase this number. Ex:
- Write good doc
- Code reviews
- Pair programming to spread knowledge of the code base
Strive to increase this number. Ex:
- Write good doc
- Code reviews
- Pair programming to spread knowledge of the code base
How do you handle data that can't fit/be processed by one machine?
Main Partition techniques
- Range based [A-C,D-G,...] Efficient range queries. Risk of hot spots -> Split the partition
- Hash based. No range queries but distributes load evenly. Check "Consistent hashing"
Main Partition techniques
- Range based [A-C,D-G,...] Efficient range queries. Risk of hot spots -> Split the partition
- Hash based. No range queries but distributes load evenly. Check "Consistent hashing"
Given an array of integers, find if the array contains any duplicates.
bool containsDuplicate(vector<int>& nums) {
unordered_set<int> s (nums.begin(), nums.end());
return s.size() != nums.size();
}
bool containsDuplicate(vector<int>& nums) {
unordered_set<int> s (nums.begin(), nums.end());
return s.size() != nums.size();
}
Becoming a coder needs focus and discipline
- Get a bit better every day
- Focus on one thing: frontend, backend, android, ios, ...
There are too many technologies.
Know a bit about everything, but become a specialist so that you can fing the type of job you want
- Get a bit better every day
- Focus on one thing: frontend, backend, android, ios, ...
There are too many technologies.
Know a bit about everything, but become a specialist so that you can fing the type of job you want
"The real money isn't in the software.
It's in the service you build with that software."
- Jeff Atwood
It's in the service you build with that software."
- Jeff Atwood
4 Common linked list interview questions
1. Reverse linked list, recursive & iterative
2. Merge two sorted linked list
3. Does a linked list have a cycle?
4. Find the intersection of two lists
5. Add numbers represented by two lists
Try to solve them (easily googable)
1. Reverse linked list, recursive & iterative
2. Merge two sorted linked list
3. Does a linked list have a cycle?
4. Find the intersection of two lists
5. Add numbers represented by two lists
Try to solve them (easily googable)
It's easier to write an incorrect program than understand a correct one