-
Notifications
You must be signed in to change notification settings - Fork 9
New issue
Have a question about this project? # for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “#”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? # to your account
Nouvelles versions cpp école primaire #10
Comments
Une autre par Gof< : #include <iostream>
template<typename F>
auto operator *(int N, F fun) -> decltype((void)fun()) {
for (int i = 0; i < N; ++i)
fun();
}
int main() {
100 * []{ std::cout << "Je ne dois pas jeter d'avion en papier en classe !" << std::endl; };
} Le |
|
|
#include <iostream>
template<int N>
void loop() {
std::cout << "Je ne dois pas jeter "
"d'avion en papier en classe" << std::endl;
if constexpr (N)
loop<N-1>();
}
int main() {
loop<99>();
} |
Le |
Du coup ça ne prends pas les objets fonctions? |
@devnewton Cela prend tous les objets |
The text was updated successfully, but these errors were encountered: