How many assignments would I have failed without brainy? Lol
ALL OF THEM
<span>To capitalize lowercase “a”
which is 0110001 which is “A” you will need to flip the following bites 01000001<span> as represented in ASCII. Since we are only looking at
2bit digit which is 0 and 1 which has a
256 possible combinations from 0 up to 255. </span></span>
Answer:
There is no short answer.
Explanation:
First let's create the string:
- alphabetString = "abcdefghijklmnopqrstuvwxyz";
The first half of the string using slice method can be written as:
- alphabetString.slice(0, 13);
The first half of the string using only the ending index can be written as:
- alphabetString.slice(-13);
When we put - at the start of the index number, the counting begins at the last element with -1 and goes backwards.
The second half of the string can be written as:
- alphabetString.slice(13,26);
The second half of the string using only the starting index can be written as:
- alphabetString.slice(13);
To get the every second letter in the string, we need a for loop:
- for( let x = 0; x < alphabetString.length(); x = x + 2){
alphabetString.slice(x);
}
To get the entire string in reverse, we can use the reverse method that is built-in:
- alphabetString.reverse();
To get the every third letter of the string, we can again use a for loop:
- for( let x = -1; x = -27; x = x - 3){
alphabetString.slice(x);
}
I hope this answer helps.