A correlation is a consistent relationship between two or more variables. It relates to our tendency to draw causation from mere correlation.
Your question wasn't very clear, but I think I understand what you want. Additionally, you should really state what language you're working with. Here it is in C#, and shouldn't be too much of a hassle to translate in to other languages.
Console.Write("Enter payment: ");
float payment;
if (float.TryParse(Console.ReadLine(), out payment))
Console.WriteLine((Math.Floor(payment * 100) / 100) * 0.15, + " at 15% tip.");
else
Console.WriteLine("Invalid input.");
In python the input() function prompts the user to enter information.