Questions tagged [alphabet]
319 questions
-1
votes
1 answer
-1
votes
2 answers
Java: Assign values to alphabet and determine value of a string
So I am trying to solve the problem in Java below. Could someone give me an idea of how to approach this? I can only think of using a bunch of confusing for-loops to split up the arr, go through the alphabet, and go through each string, and even…

jro
- 33
- 1
- 3
-1
votes
1 answer
Alphabetizing a List
I'm looking for a way to truly alphabetize a list. Assuming it's a list of basic words, such as:BlackGreenThe RedBlueWaxyLivingPorousSolidLiquidVioletIs there a way to modify this code to alphabetize the list where "The Red" comes before "Solid"?…

Shaun Doeden
- 23
- 1
-1
votes
3 answers
How to get the first alphabet character of a string in iOS
I have an example NSString in iOS
NSString* str = @"-- This is an example string";
I want to get the first alphabet letter. The result of above situation is letter "T" from word "This". Some characters before letter "T" is not alphabet letter so it…

Scofield Tran
- 828
- 1
- 18
- 30
-1
votes
2 answers
Printing the alphabet on one line python
How can I print the alphabet on one line using chr(), with each letter seperated by a space.
My current code:
for x in range(97,123):
letter = chr(x)
alphabet = "" + letter
print alphabet

user2989433
- 53
- 1
- 6
-1
votes
2 answers
How to populate a 2d char array with the alphabet
My goal is to create a 2d array of the alphabet like this:
abc
bca
cab
Such that each row and column has all 26 letters. I know I can do this the manual ugly way, but was hoping someone knows a more efficient way to populate the array.
Thank you.

north.mister
- 500
- 1
- 7
- 24
-1
votes
1 answer
How do I identify which letter of the alphabet a word starts with in Objective-C?
Given a string, I'm trying to determine which letter of the alphabet it belongs to. For example, "apple" goes into the "A" section. "Banana" goes into the "B" section. I'm using this to identify the section:
NSRange range = [string…

Hilton Campbell
- 6,065
- 3
- 47
- 79
-1
votes
2 answers
Writing the alphabet in a char *
I am struggling to find a way to write the alphabet letters in a char* using for.
If I only had to do that using a table of chars, it'd be like this
for(i=0;i<26;i++) {
character[i] = 'a' + i;
}
But I have a function that requests a char *, so…

Sebastian Luke
- 385
- 5
- 18
-1
votes
2 answers
How do people who don't use the latin alphabet use the internet?
I have a school project about how people who don't use the latin alphabet use the internet (like russians or chinese). How do they enter urls or e-mail adresses, and how do they write HTML without a latin keyboard?

The Programmer
- 83
- 1
- 1
- 8
-1
votes
3 answers
Arrange char array in sequence
I came across a post showing how to arrange char array by alphabet order.
seeing this can be done, I want to output the alphabetical order of each character of the input string, in order of the characters of the input string.
I'm a bit stuck. I can…

searchfunction
- 109
- 2
- 9
-1
votes
2 answers
Python Decoder: alphabet to numbers
I've just recently started programming in python through an online course, and on one of the assignments we were required to encode a string with rot13. I used the maketrans method and everything is well but I am curious as to how I'd go about…

user2141284
- 1
- 1
- 1
-1
votes
3 answers
Compress char[] alphabet
My best friend's girlfriend texted me and thought it would be a good idea to put some code on his cake saying happy birthday. I figured I would make an array for the alphabet, and use some serious math equations that he has to type in for it to say…

Hayden Holligan
- 1,822
- 2
- 19
- 26
-2
votes
3 answers
How to recursively print the alphabet in Javascript?
Seen some solutions using a regular for loop, but was interested in the recursive way
maybe we can define the arr as the alphabet
let arr = ['abcdefghij(...rest_of_alphabet)`]
found this on the interwebs, would this work?
Call map() using the…

zunny
- 1
- 3
-2
votes
2 answers
Cycle through letters of the alphabet in a loop and assign values to them in Python?
Here the number of variables (which correspond to numfactors) are assigned manually to each letter of the alphabet. So the first variable is A and it gets assigned the value of an array slice (paths[0:35] for example). B is set to paths[35:70],…

Matt
- 2,602
- 13
- 36
-2
votes
1 answer
why are we subtracting the code from 64 on the bottom if statment, I am confused with that line
Just wondering about the line after the if statement and why are we subtracting 64 or using 64 in the code for the string.
function alphabetPosition(text) {
var result = "";
for (var i = 0; i < text.length; i++) {
var code =…

Otis Guess
- 17
- 4