I've been through every post I could find on the subject and nothing have answered my problem;
This is the code:
output = 'Scan results for BrainS (192.168.43.111)
Scan results for Slave (192.168.43.107)
Scan results for SlaveSmall (192.168.43.242)'
while (True)
if output[i].isdigit(): # i has initial value of 15, j=0
f[j]=output[i]
j+=1
i+=1
elsif(i == len(output)):
break
else:
i+=1
continue
Print:
>>>f
['1','9','2','1','6','8','4','3','1','1','1','0','0','0']
As you can see I'm trying to extract the IP as it is with dots(in this code I didnt try to extract the dots but only the numbers), I cant figure out how do get the string I want exactly as it is: f = 192.168.43.111
Any suggestions? better commands?