Not logged in.  Login/Logout/Register | List snippets | | Create snippet | Upload image | Upload data

3
LINES

< > BotCompany Repo | #1035235 // rshift_ceil - right shift, round up

JavaX fragment (include) [tags: use-pretranspiled]

Libraryless. Click here for Pure Java version (31L/1K).

1  
static int rshift_ceil(int a, int bits) {
2  
  ret (a+(1 << bits)-1) >> bits;
3  
}

Author comment

Began life as a copy of #1020216

download  show line numbers  debug dex  old transpilations   

Travelled to 3 computer(s): bhatertpkbcr, mowyntqkapby, mqqgnosmbjvj

No comments. add comment

Snippet ID: #1035235
Snippet name: rshift_ceil - right shift, round up
Eternal ID of this version: #1035235/1
Text MD5: 65ac083c96adc104cc0608e893a8c7f6
Transpilation MD5: a441eeeed2a3e24772a9e27f30d7571a
Author: stefan
Category: javax
Type: JavaX fragment (include)
Public (visible to everyone): Yes
Archived (hidden from active list): No
Created/modified: 2022-04-20 20:28:13
Source code size: 78 bytes / 3 lines
Pitched / IR pitched: No / No
Views / Downloads: 137 / 189
Referenced in: [show references]