You can use the following code:-
#include<stdio.h>
#include<string.h>
int main(){
char str[100],rtStr[100];
int len,i,flag=0,vowel_pos,c=0;
printf("Enter the string: ");
scanf("%s",&str);
for(i=0;i<strlen(str);i++){>
if(str[i]=='a' || str[i]=='e' || str[i]=='i' || str[i]=='o' || str[i]=='u' || str[i]=='A' || str[i]=='E' || str[i]=='I' || str[i]=='O' || str[i]=='U'){
vowel_pos=i;
flag=1;
break;
}
}
if(flag==1){
while (c < (strlen(str)-vowel_pos)) {
rtStr[c] = str[vowel_pos+c];
c++;
}
for(i=0;i<vowel_pos;i++){>
rtStr[c]=str[i];
c++;
}
rtStr[c] = '\0';
printf("Rotate String is: %s",rtStr);
}
else{
printf("Rotate String is: %s",str);
}
return 0;
}