es
Feedback
Coding | EXAMS | IBM ACCENTURE | VIRTUSA | IBM | AMAZON | TCS | EPAM | WILEY EDGE | TECH MAHINDRA | JPMORGAN | HCL | WIPRO

Coding | EXAMS | IBM ACCENTURE | VIRTUSA | IBM | AMAZON | TCS | EPAM | WILEY EDGE | TECH MAHINDRA | JPMORGAN | HCL | WIPRO

Ir al canal en Telegram

Main channel https://t.me/Coding_000 Contact Admin 👉 @ILOVEU_143 for booking your exam slots Web- https://coding000.github.io/Projects/ 💯% clearance in any placement exams OffCampus -https://t.me/Offcampus_000 Discussion- https://t.me/exams_discussion

Mostrar más
3 342
Suscriptores
-224 horas
-207 días
-5530 días
Archivo de publicaciones
Any one want projects -mini or Major 😊 Domain AI/ML contact -@ILOVEU_000 Note -paid 🤑 share✅ share ✅

def variantsCount(n, s0, k, b, m, a):     if n <=0:         return 0         sum_array = [s0]     for i in range(1,n):         s_i = ((k * sum_array[i - 1] + b) % m) + 1 + sum_array[i - 1]         sum_array.append(s_i)         # two pointer to calculate the count     left = 0     right = len(sum_array) -1     count = 0     while left <= right:         area = sum_array[left] * sum_array[right]         if area <= a:             count += 2*(right - left) + 1             left +=1         elif area > a:             right -=1     return count Paint the ceiling code Python3

#include <bits/stdc++.h> using namespace std; vector<int> batonPass(int n, long t){     vector<int> ans;     int oddEven = 1,count=0;         while(true){             if(oddEven & 1){         if(count==0){           for(int i=0 ; i<n ; i++){             count++;             if(t == count){               if(i!=n-1){                 // cout << i+1 << " " << i+2;                 ans.push_back(i+1);                 ans.push_back(i+2);                 return ans;               }else{                 ans.push_back(i+1);                 ans.push_back(i);                 return ans;               }             }           }         }else{           for(int i=1 ; i<n ; i++){             count++;             if(t == count){               if(i!=n-1){                 ans.push_back(i+1);                 ans.push_back(i+2);                 return ans;               }else{                 ans.push_back(i+1);                 ans.push_back(i);                 return ans;               }             }           }         }         oddEven++;       }else{         for(int i = n-2 ; i>=0 ; i--){           count++;           if(t == count){             if(i!=0){                 ans.push_back(i+1);                 ans.push_back(i);                 return ans;             }else{                 ans.push_back(i);                 ans.push_back(i+1);                 return ans;             }           }         }         oddEven++;       }     }   } int main() {     int friends,timee;     cin >> friends >> timee;         vector<int> ans = batonPass(friends,timee);     for(auto it : ans) cout << it << " ";     return 0; } Pass the baton code 👆👆 C++

vector<int> batonPass(int friends, long time) {   vector<int> f;   int k = 1;   bool r = false;   long i = 1;   while (i <= time) {     if (!r) {       if (k <= friends)         k++;       else {         r = true;       }     } else {       if (k >= 2) {         k--;       } else {         r = false;       }     }     i++;   }   if (r) {     f.push_back(k);     f.push_back(k - 1);   } else {     f.push_back(k - 1);     f.push_back(k);   }   return f; } Pass the baton code

#include <bits/stdc++.h> using namespace std; vector<int> batonPass(int n, long t){     vector<int> ans;     int oddEven = 1,count=0;         while(true){             if(oddEven & 1){         if(count==0){           for(int i=0 ; i<n ; i++){             count++;             if(t == count){               if(i!=n-1){                 // cout << i+1 << " " << i+2;                 ans.push_back(i+1);                 ans.push_back(i+2);                 return ans;               }else{                 ans.push_back(i+1);                 ans.push_back(i);                 return ans;               }             }           }         }else{           for(int i=1 ; i<n ; i++){             count++;             if(t == count){               if(i!=n-1){                 ans.push_back(i+1);                 ans.push_back(i+2);                 return ans;               }else{                 ans.push_back(i+1);                 ans.push_back(i);                 return ans;               }             }           }         }         oddEven++;       }else{         for(int i = n-2 ; i>=0 ; i--){           count++;           if(t == count){             if(i!=0){                 ans.push_back(i+1);                 ans.push_back(i);                 return ans;             }else{                 ans.push_back(i);                 ans.push_back(i+1);                 return ans;             }           }         }         oddEven++;       }     }   } int main() {     int friends,timee;     cin >> friends >> timee;         vector<int> ans = batonPass(friends,timee);     for(auto it : ans) cout << it << " ";     return 0; } 1st code -c++

share this grp guys fast i will send all solutions @Coding_000 share share✅✅✅

Atlassian free code help 🔥🔥 Join here guys Join this group guys for free code Atlassian code free 🤘 free https://t.me/Coding_000 https://t.me/Coding_000 https://t.me/Coding_000 share ✅share✅ share ✅