FString func(int32 x)
{
FString str;
switch(x)
{
case 0 ... 999: str = FString::FromInt(x); break;
case 1000 ... 999999: str = FString::FromInt(x/1000) + "K"; break;
case 1000000 ... 999999999: str = FString::FromInt(x/1000000) + "M"; break;
default: str = FString::FromInt(x); break;
}
return str;
}