[go: up one dir, main page]

Skip to content

LiYeming/cpp_tip_of_the_week

 
 

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 
 
 
 
 
 
 

Repository files navigation

C++ Tip of The Week


Your weekly dose of modern C++ challenge (Release every Sunday).


Tips

  • [303] - Did you about typename erasure technique to reduce compilation times with templates?
  • [302] - Did you now that with concepts you can override a type?
  • [301] - Did you now that functions in are constexpr since C++23?
  • [300] - Did you know that C++23 added support for constexpr std::bitset?
  • [299] - Did you know that C++20 concepts can be used to avoid implicit conversions?
  • [298] - Did you know that C++23 added static operator()?
  • [297] - Did you know that C++20 introduced coroutines? (co_await)
  • [296] - Did you know that C++20 introduced coroutines? (co_yield)
  • [295] - Did you know that C++23 added stacktrace library?
  • [294] - Did you know that with C++20 (constexpr containers) TMP can be achieved with STL?
  • [293] - Did you know that C++17 [[nodiscard]] attribute can be applied not only to function?
  • [292] - Did you know about memoized for less types (more compile-time friendly) conditional_t?
  • [291] - Did you know about [[gnu::cold]] function attribute to mark functions which are unlikely to be called?
  • [290] - Did you know that lambda expression is guaranteed to have a unique type?
  • [289] - Did you know that [[assume]] attribute has been accepted to C++23?
  • [288] - Did you know you can pass an array by reference?
  • [287] - Did you know that C++23 added auto(x): decay-copy in the language?
  • [286] - Did you know that Circle supports Python's extended slice syntax for variadic packs?
  • [285] - Did you know about C++20 template specialization with concepts?
  • [284] - Did you know about C++23 ispanstream - A strstream replacement using span as buffer?
  • [283] - Did you know that C++23 added ranges::to (conversion from ranges to containers)?
  • [282] - Did you know about introduced in C++20 object concepts?
  • [281] - Did you know about gtest.gmock mocking framework?
  • [280] - Did you know about use cases for type-based reserved decorator?
  • [279] - Did you know that C++20 made std::string constexpr?
  • [278] - Did you know that C++23 added Literal Suffix for (signed) size_t?
  • [277] - Did you know that C++17 structured bindings support to custom classes can be added?
  • [276] - Did you know that C++23 added bind_back to simplify writing higher order functions?
  • [275] - Did you know what is the underlying type of NTTP string aka fixed_string?
  • [274] - Did you know about C++23 proposal Structured Bindings can introduce a Pack?
  • [273] - Did you know that concept can be passed via lambda expression?
  • [272] - Did you know that C++20 added std::ranges::{all_of, any_of, none_of} algorithms?
  • [271] - Did you know that C++20 added support for floating point values as non-type template parameters?
  • [270] - Did you know that C++23 added std::to_underlying?
  • [269] - Did you know about boost::mp11::mp_with_index?
  • [268] - Did you know that C++20 added std::erase_if for std::map and std::vector?
  • [267] - Did you know that C++23 added std::unreachable?
  • [266] - Did you know wrapping an unqualified function name in parentheses suppresses argument-dependent lookup?
  • [265] - Did you know that C++23 added Attributes on Lambda-Expressions?
  • [264] - Did you know that C++20 added __VA_OPT__ for comma omission and comma deletion?
  • [263] - Did you know that C++23 added std::byteswap to swap bytes?
  • [262] - Did you know that type_info equality operator is constexpr in C++23?
  • [261] - Did you know that C++23 added Monadic operations for std::optional?
  • [260] - Did you know that C++23 added std::move_only_function?
  • [259] - Did you know that static reflection supports introspecting constructors?
  • [258] - Did you know that static reflection can be used to invoke functions with named parameters?
  • [257] - Did you know that static reflection can be used to implement row polymorphism?
  • [256] - Did you know that static reflection proposal for C++2X has mirror/value based interface?
  • [255] - Did you know that static reflection proposal for C++2X can reflect functions?
  • [254] - Did you know about static reflection proposal for C++2X?
  • [253] - Did you know that C++20 extends support for data time utilities?
  • [252] - Did you know that C++23 added basic_string::resize_and_overwrite?
  • [251] - Did you know that C++20 added type_identity which implements the identity metafunction?
  • [250] - Did you know about methods to access the last element of variadic pack...?
  • [249] - Did you know that C++23 allows extended init-statement with alias-declaration in the for loop?
  • [248] - Did you know that CRTP can be implemented with C++23 Deducing this?
  • [247] - Did you know that Deducing this proposal has been voted out into C++23?
  • [246] - Did you know that C++11 added a numeric literal operator template?
  • [245] - Did you know about C++2X proposal to add Multidimensional subscript operator?
  • [244] - Did you know about compiler predefined macros assosicated with the compilation date/time?
  • [243] - Did you know about C++2X Pattern matching using is and as proposal?
  • [242] - Did you know that ANSI/ISO C++ conforming programs must not rely on a maximum template depth greater than 17 (changed to 1024 in C++11)?
  • [241] - Did you know about different ways of accessing C-style arrays by index?
  • [240] - Did you know that using-declarator can be used to manipulate the overload set?
  • [239] - Did you know that Circle Meta-model allows to convert string to a type?
  • [238] - Did you know that Circle Meta-model allows for applying normal STL for operations on @meta types?
  • [237] - Did you know about C++2X proposal for the Circle Meta-model for compilation-time meta-programming?
  • [236] - Did you know about __builtin_dump_struct clang-extension which can nicely print a struct?
  • [235] - Did you know that C++20 [[no_unique_address]] can be used to implement lazy/fast/memory efficient views?
  • [234] - Did you know about function-try-block and that exceptions caught inside that block are implicitly rethrown?
  • [233] - Did you know that C++20 made typename more optional?
  • [232] - Did you know that different overloads can have different specifiers?
  • [231] - Did you know about C++17 variadic using declaration?
  • [230] - Did you know that C++23 added if consteval?
  • [229] - Did you know about python's named tuples?
  • [228] - Did you know that C++ allows accessing private members with friend injection?
  • [227] - Did you know that std::variant become valueless by exception?
  • [226] - Did you know about C++23 feature which adds support for inheriting from std::variant?
  • [225] - Did you know about C++23 feature which removes unnecessary ()’s from C++ lambdas?
  • [224] - Did you know that the JSON standard does not specify that the insertion order of object elements should be preserved?
  • [223] - Did you know about the proposal to add json support to the standard library?
  • [222] - Did you know that C++23 added contains function to string_view?
  • [221] - Did you know that with Automatic DI production wiring can be overwritten for integration testing?
  • [220] - Did you know that with Automatic DI one can control how dependencies are being created?
  • [219] - Did you know about Automatic Dependency Injection libraries such as DI?
  • [218] - Did you know about different ways of constructor Dependency Injection?
  • [217] - Did you know the difference between fakes, stubs, mocks?
  • [216] - Did you know that you can inject singletons to improve testability?
  • [215] - Did you know C++2X Pattern Matching can be used for run-time dispatching?
  • [214] - Did you know about variadic aggregate initialization?
  • [213] - Did you know that mapping types to values is a simple way to transition from compile-time to run-time space?
  • [212] - Did you know that lambdas are const by default but can be mutable and keep state?
  • [211] - Did you know about C++2X Pattern Matching proposal?
  • [210] - Did you know about Design By Introspection?
  • [209] - Did you know about Policy Based Design?
  • [208] - Did you know that default template arguments can be explored with template template arguments?
  • [207] - Did you know about the proposal to add constexpr function parameters?
  • [206] - Did you know about proposal to add support for recursive lambdas?
  • [205] - Did you know that C++20 std::to_array supports creating from string literals?
  • [204] - Did you know that you can implement a compile-time map with C++?
  • [203] - Did you know that in C++ char, signed char and unsigned char are 3 different types?
  • [202] - Did you know that C++20 added Using Enum which introduces the enumerator names of the named enumeration as if by a using-declaration for each enumerator?
  • [201] - Did you know that sizeof operator can be used for efficient math computation?
  • [200] - Did you know that C++23 added is_scoped_enum type trait to detect whether an enum is scoped?
  • [199] - Did you know about proposal to introduce constexpr ternary operator?
  • [198] - Did you know about different ways of iterating over objects?
  • [197] - Did you know that Lambdas in Unevaluated Context combined with Template Constraints (Concepts) can be used with types?
  • [196] - Did you know that Lambdas in Unevaluated Context combined with Immediately Invoked Function Expressions (IIEF) can be used to simplify Template Meta-Programming?
  • [195] - Did you know that C++20 added support for [[no_unique_address]] attribute?
  • [194] - Did you know about C++23 proposal to add views::enumerate?
  • [193] - Did you know that C++20 added support for constexpr new?
  • [192] - Did you know about std::expected proposal for error handling?
  • [191] - Did you know that expression evaluation order is not specified?
  • [190] - Did you know that C++20 added ostream_joiner that writes successive objects into the basic_ostream separated by a delimiter?
  • [189] - Did you know that Compile Time Regular Expressions support extracting matches?
  • [188] - Did you know about proposal to add Compile Time Regular Expressions?
  • [187] - Did you know that C++17 made exception specifications be part of the type system?
  • [186] - Did you know Non-Type Template Parameters (NTTP) with User-Defined Literals (UDL) can be used to get compile-time strings?
  • [185] - Did you know about the proposal to make printf compile-time safe and with named arguments?
  • [184] - Did you know that you can customize formatter for your classes with std::format?
  • [183] - Did you know that Formatted output has been accepted into C++20?
  • [182] - Did you know about the proposal to add Non-terminal variadic template parameters?
  • ...

Disclaimer Quantlab Financial is not responsible for the correction of solutions and/or reserves the right to contact/reward contributors.

About

C++ Tip Of The Week

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published