Forget all that "C" old bit operator, you are "C++", use the modern STL way ;)
#include <bitset>
#include <iostream>
void PrintLogicalDrives()
{
using namespace std;
bitset lt< 'Z' - 'A' + 1 > ld = (int)GetLogicalDrives();
for( char i = 'A'; i <= 'Z'; i++ )
{
if( ld[ i - 'A' ] )
cout << i << ":" << endl;
}
}