I need to trim a given IP Address to get the first 3 parts of it
Example:
"192.168.1.20" ➨ "192.168.1." "29.6.60.241" ➨ "29.6.60."
String result = input.Substring(0, input.LastIndexOf("."));