fixed bug in alphabetize()
This commit is contained in:
		@@ -21,9 +21,11 @@ static char* alphabetize(weylgroup_element_t *e, char *str)
 | 
				
			|||||||
{
 | 
					{
 | 
				
			||||||
  if(e->wordlength == 0)
 | 
					  if(e->wordlength == 0)
 | 
				
			||||||
    sprintf(str, "1");
 | 
					    sprintf(str, "1");
 | 
				
			||||||
  else
 | 
					  else {
 | 
				
			||||||
    for(int j = 0; j < e->wordlength; j++)
 | 
					    for(int j = 0; j < e->wordlength; j++)
 | 
				
			||||||
      sprintf(str, "%c", e->word[j] + 'a');
 | 
					      str[j] = e->word[j] + 'a';
 | 
				
			||||||
 | 
					    str[e->wordlength] = 0;
 | 
				
			||||||
 | 
					  }
 | 
				
			||||||
 | 
					
 | 
				
			||||||
  return str;
 | 
					  return str;
 | 
				
			||||||
}
 | 
					}
 | 
				
			||||||
 
 | 
				
			|||||||
		Reference in New Issue
	
	Block a user