Nice content! I'm asking if there is any technique or intuition to solve problems that tells you to find number of pairs or triplets or quadruplets that satisfy a given proprety?
Nice Explanation Sir. Problem A can be also solved in O(1). Approach: First We can try dividing the number equally , and then since we had to make it lexographically as small as possible, so we can try to first try to make 1st letter as “1” and put all extra elements in the last letter, and similarly try to make 2nd letter as “1” and put all extra elements into last letter. Now if further possibility remains, try to put some element from 1st letter to 2nd letter Code:- void solve() { int n; cin >> n; int each = n / 3; int rem = n % 3; int last = each; int slast = each; int first = each; if (rem == 1) { last++; } else if (rem == 2) { if (last + 2 > 26) { slast++; last++; } else { last += 2; } } // cout
All codes you can find in my codeforces, link already present in description. For the voice, can you tell me what's the issue you're seeing. If it is something related to voice breaking or noise, I will try to fix it.
F is also a very conceptual problem, which teach us the concept for finding cycles in the directed graph
Nice content!
I'm asking if there is any technique or intuition to solve problems that tells you to find number of pairs or triplets or quadruplets that satisfy a given proprety?
you are too good in explaining please continue it.
Best explanation seen so far
Great sir we need more educational videos from you
try to explain your code also with your logic explanation
it really clears the understanding
atleast in F and G problems.
hey abhishek bhaia ! I am a 1st year student and wanted to start with cp can pls tell how should i start i have basic understanding of data structures
Nice Explanation Sir. Problem A can be also solved in O(1).
Approach:
First We can try dividing the number equally , and then since we had to make it lexographically as small as possible, so we can try to first try to make 1st letter as “1” and put all extra elements in the last letter, and similarly try to make 2nd letter as “1” and put all extra elements into last letter. Now if further possibility remains, try to put some element from 1st letter to 2nd letter
Code:-
void solve()
{
int n;
cin >> n;
int each = n / 3;
int rem = n % 3;
int last = each;
int slast = each;
int first = each;
if (rem == 1) {
last++;
} else if (rem == 2) {
if (last + 2 > 26) {
slast++;
last++;
} else {
last += 2;
}
}
// cout
Yes correct
I also did the same with O(1) time complexity
ll n;
cin>>n;
ll rem=n%26;
if(rem==0) {
if(n/26==1) cout
if (n
thank you!
please give the link of modulus arithmetic concept for D problem as the comment in which you gave is deleted now
Great explanation.
Thanks sir
mind blowinng
please make a separate video with code and good voice quality plz
All codes you can find in my codeforces, link already present in description.
For the voice, can you tell me what's the issue you're seeing. If it is something related to voice breaking or noise, I will try to fix it.
Superb explanation sir🎉
Just now only posted 😂. you Watched full video
@@Cools74 yeah bro
True Appreciation ♥ :D
Crazyyyy
Make more often.
make more videos like this
Hindi m banao Bhai please