x_function remains the same
(value: u32)
| 33 | |
| 34 | // x_function remains the same |
| 35 | pub fn x_function(value: u32) -> u32 { |
| 36 | match value { |
| 37 | 0 => 0, |
| 38 | 1 => 1, |
| 39 | 2 => 1, |
| 40 | 3 => 2, |
| 41 | 4 => 1, |
| 42 | 5 => 2, |
| 43 | 6 => 2, |
| 44 | 7 => 3, |
| 45 | 8 => 1, |
| 46 | 9 => 2, |
| 47 | 10 => 2, |
| 48 | 11 => 3, |
| 49 | 12 => 2, |
| 50 | 13 => 3, |
| 51 | 14 => 3, |
| 52 | 15 => 4, |
| 53 | _ => 0, // Invalid input |
| 54 | } |
| 55 | } |
| 56 | |
| 57 | pub fn shift_and_accumulate(value: u32) -> u32 { |
| 58 | let high = (value >> 16) as u16; |
no outgoing calls
no test coverage detected