title: bubble sort a character array in alphabetic order in c
body: <p>I'm trying to bubble sort a character array in alphabetic order.
  My code is as follows:</p>
  
  <pre><code>#define CLASS_SIZE 10
  #include &lt;stdio.h&gt;
  
  void bubbleSortAWriteToB(const char a[], char *b[]);
  
  int main(void){
      char *s_letters[CLASS_SIZE];
      char letters[CLASS_SIZE] = {'a','r','p','b','r','c','x','e','w','j'};
      bubbleSortAWriteToB(letters,s_letters);
          return 0;
  }
  
  void bubbleSortAWriteToB(const char a[], char *b[]){
      char temp;
      int i,j;
      for(i=0;i&lt;CLASS_SIZE-1;i++){
          for(j=1;j&lt;CLASS_SIZE;j++){
              if((int)a[j-1]&gt;(int)a[j]){
                  temp = a[j];
                  *b[j] = a[j-1];
                  *b[j-1] = temp;
  
              }
  
      }
  
    }
  }
  </code></pre>
  
  <p>It doesn't give any kind of error but when i run it it gets stuck like it's kinda in a inifinte loop. But from what i can see it isn't that either. Can you help me out?</p>