ПК
Size: a a a
ПК
AB
AB
D
template <size_t... I>
void call_foo(std::index_sequence<I...>) {
(foo<I>(), ...);
}
template <size_t... I, typename... Args>Заработает?)
void call_foo(std::index_sequence<I...>) {
(foo<I, Args...>(), ...);
}
call_foo<T1, T2, T3>(std::make_index_sequence<n>{});
D
foo
ещё и I
пытаться раскрыть первым ...
D
AB
template <size_t... I, typename... Args>Заработает?)
void call_foo(std::index_sequence<I...>) {
(foo<I, Args...>(), ...);
}
call_foo<T1, T2, T3>(std::make_index_sequence<n>{});
AB
template <typename... Ts> struct type_list {}
спасетЕ
template <size_t... I, typename... Args>Заработает?)
void call_foo(std::index_sequence<I...>) {
(foo<I, Args...>(), ...);
}
call_foo<T1, T2, T3>(std::make_index_sequence<n>{});
D
D
D
D
Е
D
D
M
size_t count = count_if(str.begin(), str.end(), [](char ch) {
return isupper(ch);
});
if ((count == str.length()) ||
(count == str.length() - 1 && islower(str.front()))) {
bool flag = true;
for_each(str.begin(), str.end(), [&] (char &ch) {
if(ch == toupper(ch))
ch = tolower(ch);
else if (flag) {
ch = toupper(ch);
flag = false;
}
else ch = tolower(ch);
});
AP
AS
size_t count = count_if(str.begin(), str.end(), [](char ch) {
return isupper(ch);
});
if ((count == str.length()) ||
(count == str.length() - 1 && islower(str.front()))) {
bool flag = true;
for_each(str.begin(), str.end(), [&] (char &ch) {
if(ch == toupper(ch))
ch = tolower(ch);
else if (flag) {
ch = toupper(ch);
flag = false;
}
else ch = tolower(ch);
});
M