id/email
password
forgot password | create account
about | help | code help+videos | done | prefs
CodingBat code practice

 

orion.a.smith@gmail.com apcsa-encryption > apcsaEncryptToAlphaNums
prev  |  next  |  chance

Given an input String consisting of only uppercase letters, change each letter into a number representing that letter's position in the alphabet and return an ArrayList of Integer values representing those positions. So 'A' becomes 0, 'B' becomes 1, ..., 'Z' becomes 25.


apcsaEncryptToAlphaNums("ABC") → [0, 1, 2]
apcsaEncryptToAlphaNums("XYZ") → [23, 24, 25]
apcsaEncryptToAlphaNums("FEEDTHEMETER") → [5, 4, 4, 3, 19, 7, 4, 12, 4, 19, 4, 17]

...Save, Compile, Run (ctrl-enter)

public ArrayList<Integer> apcsaEncryptToAlphaNums(String str) { }

Editor font size %:
Shorter output


Forget It! -- delete my code for this problem

Progress graphs:
 Your progress graph for this problem
 Random user progress graph for this problem
 Random Epic Progress Graph

Java Help

Misc Code Practice

Difficulty: 310

Copyright Nick Parlante 2017 - privacy