Answer:
def scramble(s):
if len(s) % 2 == 1:
index = int(len(s)//2)
else:
index = int(len(s)/2)
return s[index:] + s[:index]
Explanation:
Create a function called scramble that takes one parameter, s
Check the length of the s using len function. If the length is odd, set the index as the floor of the length/2. Otherwise, set the index as length/2. Use index value to slice the s as two halves
Return the second half of the s and the second half of the s using slice notation (s[index:] represents the characters from half of the s to the end, s[:index] represents the characters from begining to the half of the s)
Answer
yo im sorry give me points b
Explanation:
gasefe
Answer:
I do!
Explanation:
Im right in the middle of those ages
Answer:
The correct answer is C.
Explanation:
You have to do 0xFF20 - 0x1037 but first, you need to convert the counts from hexadecimal base system to decimal base system using this formula:
, where position of the x₀ is the rightmost digit of the number.
<em>Note: </em>
- A = 10.
- B = 11.
- C = 12.
- D = 13.
- E = 14.
- F = 15.
0xFF20 = 15*16³+15*16²+2*16¹ = 65312
0x1037 = 1*16³+3*16¹+7*16⁰ = 4151
Result: 65312 - 4151 = 61161