C++ Bubble Sort for Data Structures