Namensräume
Varianten

operator&,|,^(std::bitset)

Aus cppreference.com
< cpp‎ | utility‎ | bitset

 
 
 
std::bitset
Mitglied Typen
Original:
Member types
The text has been machine-translated via Google Translate.
You can help to correct and verify the translation. Click here for instructions.
bitset::reference
Member-Funktionen
Original:
Member functions
The text has been machine-translated via Google Translate.
You can help to correct and verify the translation. Click here for instructions.
bitset::bitset
bitset::operator==
bitset::operator!=
Elementzugriff zerstört
Original:
Element access
The text has been machine-translated via Google Translate.
You can help to correct and verify the translation. Click here for instructions.
bitset::operator[]
bitset::test
bitset::all
bitset::any
bitset::none
(C++11)

 
bitset::count
Kapazität
Original:
Capacity
The text has been machine-translated via Google Translate.
You can help to correct and verify the translation. Click here for instructions.
bitset::size
Modifiers
Original:
Modifiers
The text has been machine-translated via Google Translate.
You can help to correct and verify the translation. Click here for instructions.
bitset::operator&=
bitset::operator|=
bitset::operator^=
bitset::operator~
bitset::operator<<=
bitset::operator>>=
bitset::operator<<
bitset::operator>>
bitset::set
bitset::reset
bitset::flip
Conversions
Original:
Conversions
The text has been machine-translated via Google Translate.
You can help to correct and verify the translation. Click here for instructions.
bitset::to_string
bitset::to_ulong
bitset::to_ullong(C++11)
Non-Member-Funktionen
Original:
Non-member functions
The text has been machine-translated via Google Translate.
You can help to correct and verify the translation. Click here for instructions.
operator&
operator|
operator^
operator<<
operator>>
Helper-Klassen
Original:
Helper classes
The text has been machine-translated via Google Translate.
You can help to correct and verify the translation. Click here for instructions.
std::hash(C++11)
 
bitset<N> operator&(const bitset<N>& lhs, const bitset<N>& rhs );
(1)
bitset<N> operator|(const bitset<N>& lhs, const bitset<N>& rhs );
(2)
bitset<N> operator^(const bitset<N>& lhs, const bitset<N>& rhs );
(3)
Führt einen binären AND, OR und XOR zwischen zwei BitSets, lhs und rhs .
Original:
Performs binary AND, OR, and XOR between two bitsets, lhs and rhs.
The text has been machine-translated via Google Translate.
You can help to correct and verify the translation. Click here for instructions.
1)
Gibt eine bitset<N>, das das Ergebnis der binären UND auf entsprechende Paare von Bits der lhs und rhs .
Original:
Returns a bitset<N> containing the result of binary AND on corresponding pairs of bits of lhs and rhs.
The text has been machine-translated via Google Translate.
You can help to correct and verify the translation. Click here for instructions.
2)
Gibt eine bitset<N>, das das Ergebnis der binären OR am entsprechenden Paare von Bits und lhsrhs .
Original:
Returns a bitset<N> containing the result of binary OR on corresponding pairs of bits of lhs and rhs.
The text has been machine-translated via Google Translate.
You can help to correct and verify the translation. Click here for instructions.
3)
Gibt eine bitset<N>, das das Ergebnis der binären XOR auf entsprechende Paare von Bits der lhs und rhs .
Original:
Returns a bitset<N> containing the result of binary XOR on corresponding pairs of bits of lhs and rhs.
The text has been machine-translated via Google Translate.
You can help to correct and verify the translation. Click here for instructions.

Inhaltsverzeichnis

[Bearbeiten]Parameter

lhs -
die bitset auf der linken Seite des Fahrers
Original:
the bitset on the left-hand side of the operator
The text has been machine-translated via Google Translate.
You can help to correct and verify the translation. Click here for instructions.
rhs -
die bitset auf der rechten Seite des Fahrers
Original:
the bitset on the right-hand side of the operator
The text has been machine-translated via Google Translate.
You can help to correct and verify the translation. Click here for instructions.

[Bearbeiten]Rückgabewert

1)
{{{1}}}
Original:
{{{2}}}
The text has been machine-translated via Google Translate.
You can help to correct and verify the translation. Click here for instructions.
2)
{{{1}}}
Original:
{{{2}}}
The text has been machine-translated via Google Translate.
You can help to correct and verify the translation. Click here for instructions.
3)
{{{1}}}
Original:
{{{2}}}
The text has been machine-translated via Google Translate.
You can help to correct and verify the translation. Click here for instructions.

[Bearbeiten]Ausnahmen

noexcept specification:  
noexcept
  (seit C++11)

[Bearbeiten]Beispiel

#include <bitset>#include <iostream>   int main(){std::bitset<4> b1("0110");std::bitset<4> b2("0011");std::cout<<"b1 & b2: "<<(b1 & b2)<<'\n';std::cout<<"b1 | b2: "<<(b1 | b2)<<'\n';std::cout<<"b1 ^ b2: "<<(b1 ^ b2)<<'\n';}

Output:

b1 & b2: 0010 b1 | b2: 0111 b1 ^ b2: 0101

[Bearbeiten]Siehe auch

führt binäre AND, OR, XOR und NOT
Original:
performs binary AND, OR, XOR and NOT
The text has been machine-translated via Google Translate.
You can help to correct and verify the translation. Click here for instructions.

(öffentliche Elementfunktion)[edit]
close