Skip to content
Sign upLog in
Profile icon

Indika Madurapperuma

@CodingSL
Repls
Community
CodingSL
CodingSL
shared a Post
2 years ago
1
Map Cordinates Python
A road map defines locations as map references like B3, where B is the x-coordinate value and 3 is the y-coordinate. image The grid lines are 0.5 km
SixBeeps
SixBeeps
This sounds like a job for the distance formula! To calculate the distance between two points in 2D space, use this formula: ![image] (https://storage.googleapis.com/replit/images/1588858280061_e609e5852afab9c326d22d40ab6d33dd.png) where the X's and Y's are the coordinates of the two points. All you'd need to do then is to convert those letters into points, prefferably by keeping an array of letters and finding the index of each.2 years ago
CodingSL
CodingSL
shared a Post
2 years ago
2
Hi guys. I'm new to learning python coding. I'm praticing some online problems in the internet but I got stuck, Can anybody instruct me please? So my
CulturedConsiderableStruct
Python
AtticusKuhn
AtticusKuhn
try user_input = "1 2 3 3 2; 2 212 2 2" list0 = userinput.split(";")[0].split(" ") list1 = userinput.split(";")[1].split(" ") print(set(list0).intersection(list1)) `2 years ago
BraylanBB121
BraylanBB121
So are you trying to print a combined list of the 2 lists? Or are you trying to print 2 different lines on how many times it occured in the list?2 years ago