Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- public class Test
- {
- static void Main(string[] args)
- {
- int t = int.Parse(Console.ReadLine());
- for (int i = 0; i < t; i++)
- {
- string wynik = Konwertuj(float.Parse(Console.ReadLine()));
- string[] tab = wynik.Split('-');
- wynik = "";
- for (int j = tab.Length - 1; j >= 0; j--)
- {
- if (tab[j][0] == '0')
- {
- wynik += tab[j][1];
- }
- else
- {
- wynik += tab[j];
- }
- if (j>0)
- {
- wynik += " ";
- }
- }
- Console.WriteLine(wynik.ToLower());
- }
- }
- private static string Konwertuj(float v)
- {
- return BitConverter.ToString(BitConverter.GetBytes(v));
- }
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement