Girls Who Code Product Function
public int Product(int a, int b) { //Calculate a and b's product without using the operator * if(b == 1){ return a; } else if(b == 2){ return a+a; } else if(b == 3){ return a+a+a; } else if(b == 4){ return a+a+a+a; } else if(b == 5){ return a+a+a+a+a; } else if(b == 6){ return a+a+a+a+a+a; } else if(b == 7){ return a+a+a+a+a+a+a; } else if(b == 8){ return a+a+a+a+a+a+a+a; } else if(b == 9){ return a+a+a+a+a+a+a+a+a; } else if(b == 10){ return a+a+a+a+a+a+a+a+a+a; } else{ throw new IllegalArgumentException("The multiplier is too large."); } } girls who CODE
Изображение сочетает фрагмент Java-кода и стилизованную надпись «girls who CODE». Функция вычисляет произведение сложением числа a нужное количество раз, потому что автор избегает оператора умножения; шутка высмеивает чрезмерно буквальное и неэффективное решение простой задачи. EN: The image combines a Java code fragment with the stylized phrase “girls who CODE.” The function calculates a product by adding a the required number of times because the author avoids the multiplication operator; the joke mocks an overly literal and inefficient solution to a simple problem.
#programming#программирование#java#ява#coding#кодинг#girls who code#девушки программируют#software developer#разработчик программного обеспечения#multiplication#умножение#addition#сложение#inefficient code#неэффективный код#programmer humor#юмор программистов#code meme#мем про код#reaction#реакция#comic#комикс#pink meme#розовый мем
- @gentoomemes / 6813 2023-10-19
- Type
- image
- Size
- 652×669 · 73.2 KiB
- Mood
- саркастичный, абсурдный
- Language
- en
- Added