خرید بک لینک

Vote count: 0

I need to extract information from this string (was bytes, but I decoded it):

x00x00x00!broadcast "updatedirection 126.0"

I need to see whether it contains broadcast, updatedirection and also see what the number is at the end. My first solutions were:

data = data.split('!')
data = data[1]

but the symbol in that position seemed to change randomly and with no apparent patte at all. Then I tried:

data = data[12:]

But the string length changed all the time, so that didn't work.

I am doing this for a computer science project in school where I am using BYOB (based on Scratch, a simple language to teach young people how to program) and sockets to send data between them to make a LAN multiplayer. This is literally the only thing that doesn't work yet.

Hope someone can give me a solution to find this data.

asked 43 secs ago

برچسب: نویسنده: استخدام کار تاريخ: يکشنبه 26 ارديبهشت 1395 ساعت: 20:09

صفحه بندی