Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- public int substitute(int letter) {
- if((letter - position) >= 0){
- return this.mapping[letter-position] + position;
- }
- else{
- return this.mapping[((letter-position) + 26)] + position;
- }
- }
- public int substituteBack(int letter){
- if((letter - position) >= 0){
- return inverseMapping[letter - position] + position;
- }
- else{
- return inverseMapping[((letter - position) + 26)] + position;
- }
- }
Advertisement
Add Comment
Please, Sign In to add comment