Search
 
SCRIPT & CODE EXAMPLE
 
CODE EXAMPLE FOR CPP

three-way comparison c++

	lhs <=> rhs //Since C++20 
The expression returns an object that:
- compares <0 if lhs < rhs
- compares >0 if lhs > rhs
- compares ==0 if lhs and rhs are equal/equivalent.
 
PREVIOUS NEXT
Tagged: #comparison
ADD COMMENT
Topic
Name
7+6 =