English
Open in Telegram
CC++ vs Python
C++ vs Python
@cpp_vs_python · group · Tech · indexed since 2026-08-18 19 April 2023
114members
39 409messages in the index

Messages on 19 April 2023

2023-04-19×
19 April 2023
S
Photo
click to show
! Qande belgilanadi c++ da
  1. I
    faktorial digani birdan o'zigacha ko'paytirish diganida to'rimi
      1. I
        hisoblidigan funksiyani tashadin JS da yozilgan C++ ga o'tkazvalasizda bir biriga o'xshidi
Whole thread · 6 replies →
I
function Fact(a) { if (a == 1) { return 1 } else { return a * Fact(a - 1); } } shu ko'd ishlasa kere
    1. I
      rekursiya dib qidirib bir o'qib chiqin maslahatim
    1. I
      man funksiyani o'zini ichida o'zini chaqirvamman shunga ahamiyat berin bunda a-1 ni hisoblab keturadi cheksizlikkacha kereli joyida to'xtatilmasa
Whole thread · 5 replies →
I
function Fact(a) { if (a == 1) { return 1 } else { return a * Fact(a - 1); } } bu kod ishlidi oldingisi hatoyakan yepadiginiyam o'zgartirib qo'ydim
I
Photo
click to show
Assalomu alaykum. C++ dasturlash tilida shu misolga yordam bera oladiganlar bormi faqat tezroq iltimos
Whole thread · 1 reply →
  1. D
    #include <iostream> #include <cmath> using namespace std; int main (){ int n, m, s=0, y; cin>>n>>m; int x=n%pow(10,m); while(x!=0){ y=x%10; s+=y; x/=10; } cout<<s; }
Whole thread · 2 replies →
D
#include <iostream> #include <cmath> using namespace std; int main (){ int n, m, s=0, y; cin>>n>>m; int x=n%int(pow(10,m)); while(x!=0){ y=x%10; s+=y; x/=10; } cout<<s; } /stdin 123 2
J
#include <iostream> #include <cmath> using namespace std; int main (){ int n, m, s=0, y; cin>>n>>m; int x=n%int(pow(10,m)); while(x!=0){ y=x%10; s+=y; x/=10; } cout<<s; } /stdin 1232 2
J
#include <iostream> #include <cmath> using namespace std; int main (){ int n, m, s=0, y; cin>>n>>m; int x=n%int(pow(10,m)); while(x!=0){ y=x%10; s+=y; x/=10; } cout<<s; } /stdin 1232 2
J
Savolni tushunishimcha 1234 kiritib m ga 2 kiritsayiz 3+4 shuni natijasini chiqarishi kerak emasmidi
Whole thread · 1 reply →
.
#include <iostream> #include <set> #include <string> int main() { std::set<std::string> evenLengthSet; std::multiset<std::string> oddLengthSet; std::multiset<std::string> allSet; // Juft uzunlikdagi elementdan iborat to'plamni yaratish std::string evenLengthArray[] = {"one", "two", "three", "four", "five", "six"}; int evenLengthArraySize = sizeof(evenLengthArray) / sizeof(evenLengthArray[0]); // Juft uzunlikdagi elementlarni to'plamga qo'shish for (int i = 0; i < evenLengthArraySize; ++i) { if (evenLengthArray[i].length() % 2 == 0) { evenLengthSet.insert(evenLengthArray[i]); } } // Toq uzunlikdagi elementdan iborat to'plamni yaratish std::string oddLengthArray[] = {"apple", "banana", "orange", "pear", "kiwi"}; int oddLengthArraySize = sizeof(oddLengthArray) / sizeof(oddLengthArray[0]); // Toq uzunlikdagi elementlarni to'plamga qo'shish for (int i = 0; i < oddLengthArraySize; ++i) { if (oddLengthArray[i].length() % 2 != 0) { oddLengthSet.insert(oddLengthArray[i]); } } // Barcha elementlarni bir to'plamga qo'shish allSet.insert(evenLengthSet.begin(), evenLengthSet.end()); allSet.insert(oddLengthSet.begin(), oddLengthSet.end()); // Ikki to'plamdan ham bir xil qiymatli elementlarni o'chirib tashlash for (std::string s : evenLengthSet) { oddLengthSet.erase(s); allSet.erase(s); } // Hosil qilingan to'plamlarni ekranga chiqarish std::cout << "Even Length Set: "; for (std::string s : evenLengthSet) { std::cout << s << " "; } std::cout << std::endl; std::cout << "Odd Length Set: "; for (std::string s : oddLengthSet) { std::cout << s << " "; } std::cout << std::endl; std::cout << "All Set: "; for (std::string s : allSet) { std::cout << s << " "; } std
.
#include <iostream> using namespace std; int main() { const int width = 10; const int height = 6; for (int row = 1; row <= height / 2; ++row) { for (int col = 1; col <= (height - row); ++col) { cout << " "; } for (int col = 1; col <= (2 * row - 1); ++col) { if (col == 1 || col == (2 * row - 1)) { cout << "/"; } else { cout << " "; } } cout << endl; } for (int row = height / 2 + 1; row <= height; ++row) { for (int col = 1; col <= (row - 1); ++col) { cout << " "; } for (int col = 1; col <= (2 * height - 2 * row + 1); ++col) { if (col == 1 || col == (2 * height - 2 * row + 1)) { cout << "\\"; } else { cout << " "; } } cout << endl; } for (int row = 1; row <= height; ++row) { for (int col = 1; col <= width; ++col) { if (col == 1 || col == width) { cout << "|"; } else { cout << " "; } } cout << endl; } return 0; }
.
Dasturlash 2 C C++ Python Informatika Test Kimda boʻlsa lichga 💸
!
chatgpt account uzbekcoders sertifikati kimga kerak bo'lsa lichga arzon va ishonchli

An open public feed from the search index ChatCrawler — “Google for public Telegram”; refreshed as the venue is crawled. Times are UTC.

Public content only, official Telegram API. About · FAQ · Index limits · Remove a page · Catalog · Search · How we count