summaryrefslogtreecommitdiff
path: root/3/5_arith_and_logic/sarl.c
blob: 51e6305bab8131fde4b78a1dd0c0452fd0450abd (plain)
1
2
3
4
5
6
7
8
9
10
11
#include <stdio.h>

long shift_left4_rightn(long x, long n) {
    x <<= 4;
    x >>= n;
    return x;
}

int main() {
    printf("%d", shift_left4_rightn(15, 5));
}