Codeforces 287A - Div2 - IQ Test (Arabic)

  Рет қаралды 19,299

Arabic Competitive Programming

Arabic Competitive Programming

Күн бұрын

Пікірлер: 17
@harthaal-oufi2827
@harthaal-oufi2827 9 жыл бұрын
شكرا استاذ مصطفى و ان شاء الله يكون كل تعبك و مجهودك في ميزان حسناتك يا رب ... انا حليت السؤال قبل ما اشوف الفيديو مثل ما حكيت و وصلت لفكرة حلوة : * الف على كل مربع 2*2 من خلال 4 loop و في كل مرة اعد عدد الهاش و اذا كان العدد !2 بكون YES for(int k = 0; k < 3; k++) for(int s = 0; s < 3; s++) { int count = 0; for(int i = s; i < s + 2; i++) for(int j = k; j < k + 2; j++) if(arr[i][j] == '#') count++;
@ArabicCompetitiveProgramming
@ArabicCompetitiveProgramming 9 жыл бұрын
Goood
@hussein-alemam
@hussein-alemam 9 ай бұрын
I used the same idea but different implementation here is my code: #include using namespace std; bool pass(char a, char b, char c, char d) { int nOfB = 0; if (a == '#') nOfB++; if (b == '#') nOfB++; if (c == '#') nOfB++; if (d == '#') nOfB++; return nOfB != 2; } int main() { vector p(4); for (int i = 0; i < 4; ++i) cin >> p[i]; for (int i = 0; i < 3; ++i) for (int j = 0; j < 3; ++j) if (pass(p[i][j], p[i][j + 1], p[i + 1][j], p[i + 1][j + 1])) { cout
@shuilyrahman1984
@shuilyrahman1984 8 жыл бұрын
Sir could you please upload subtitles ? That would be very helpful. Thanks for these videos and your works.
@hassancena4373
@hassancena4373 9 жыл бұрын
Arabic Competitive Programming انا عندى سؤال معلش هو ال header الكتيرى اللى فى الكود اللى حضرتك رفعو دى لازمتها ايه انا بقصيت على الكود بتاعك و قارنتة بالكود بتاعى هو تقريبا نفس الفكرة بس ال headers و ال macros دول انا مش عارف ايه الفادة منهم انا عملتو ب iostream و ب stdio بس و شكرا
@ArabicCompetitiveProgramming
@ArabicCompetitiveProgramming 9 жыл бұрын
Forget about them....sometimes I am lazy and include many headers to avoid compilers errors of missing libraries
@ArabicCompetitiveProgramming
@ArabicCompetitiveProgramming 9 жыл бұрын
Macros shorten code and time...so learn them
@hassancena4373
@hassancena4373 9 жыл бұрын
Arabic Competitive Programming okay thanks
@alialaaeldinelsayed125
@alialaaeldinelsayed125 2 жыл бұрын
يا دكتور مصطفي انا عملت الحل قبل ما ابص علي حل حضرتك بس مقدرتش افهم حلك انا مستوايا مبتدأ شوية مش بعرف اعمل functions واناديها بالطريقة الي حضرتك بتعملها يعني باختصار بحس اني تايه #include using namespace std; int main (){ char arr[4][4]; for(int i = 0 ; i < 4 ; i++) for(int j = 0 ; j < 4 ; j++){ cin>>arr[i][j]; } int flag = 0; int flag2 = 0; for(int i = 0 ; i =3){ cout
@hosamqalalwa4919
@hosamqalalwa4919 2 жыл бұрын
انا ما بعرف برمجة هل المحتوى الي على القناة يكفي اتعلم c++
@ArabicCompetitiveProgramming
@ArabicCompetitiveProgramming 2 жыл бұрын
t.me/mostvision/168
@alikansoh4604
@alikansoh4604 2 ай бұрын
tjis is not te best way to do it tis is it: #include #include #include #include #include #include #include using namespace std; int main() { int n,n1=0,n2=0,v1=0,v2=0,v=0; cin >> n; for (int i = 1; i > v; if (v % 2 == 0)v1 = i; if (v % 2 != 0)v2 = i; if (v % 2 == 0)n1++; else n2++; } int h = n1>n2; if (h) cout
@fidaaahmad6547
@fidaaahmad6547 Жыл бұрын
انا حليتو هيك # include using namespace std ; bool is_Square(char a[4][4]) { for(int i = 0 ; i < 3 ; i++) for(int j = 0 ; j < 3 ; j++) if(a[i][j] == a[i][j+1] && (a[i][j] == a[i+1][j] || a[i+1][j+1] == a[i][j]) ||(a[i+1][j] == a[i+1][j+1]&&(a[i][j]==a[i+1][j]||a[i][j+1] == a[i+1][j]))) return true ; return false ; } int main(){ ios::sync_with_stdio(false); cin.tie(0); char a[4][4] ; for(int i = 0 ; i < 4 ; i++) for(int j = 0 ; j < 4 ; j++) cin >> a[i][j] ; cout
Codeforces 296A - Div2 - Yaroslav and Permutations (Arabic)
10:58
Arabic Competitive Programming
Рет қаралды 7 М.
Codeforces 289A - Div2 - Polo the Penguin and Segments (Arabic)
6:05
Arabic Competitive Programming
Рет қаралды 8 М.
Мама у нас строгая
00:20
VAVAN
Рет қаралды 6 МЛН
МЕНЯ УКУСИЛ ПАУК #shorts
00:23
Паша Осадчий
Рет қаралды 4,4 МЛН
The Ultimate Sausage Prank! Watch Their Reactions 😂🌭 #Unexpected
00:17
La La Life Shorts
Рет қаралды 6 МЛН
Trapped by the Machine, Saved by Kind Strangers! #shorts
00:21
Fabiosa Best Lifehacks
Рет қаралды 40 МЛН
Difference between HackerRank, LeetCode, topcoder and Codeforces
13:04
ICPC - Thinking Techniques - Approaching Problem Statement
17:13
Arabic Competitive Programming
Рет қаралды 51 М.
Codeforces 298A - Div2 - Snow Footprints (Arabic)
8:02
Arabic Competitive Programming
Рет қаралды 6 М.
التفكير من خلال الممارسة - 1 - السؤال
22:40
Arabic Competitive Programming
Рет қаралды 10 М.
Number Theory - Primes (Arabic)
24:23
Arabic Competitive Programming
Рет қаралды 36 М.
UI/UX Course | UI/UX Free Course | UI/UX Training | Intellipaat
3:34:54
CodeForces 287A - IQ - Test
15:36
SolverToBe
Рет қаралды 1,9 М.
Online Judge - Codeforces (Arabic)
15:54
Arabic Competitive Programming
Рет қаралды 33 М.
Мама у нас строгая
00:20
VAVAN
Рет қаралды 6 МЛН