Post History
#8: Post edited
Sort letters by height
- Sort letters by height [FINALIZED]
- Given a sequence of lower case letters, sort them into order of height.
- ## Heights
- The heights of letters are dependent on font, so for this challenge the height order to be used is as defined below:
- ```text
- acemnorsuvwxz
- t
- i
- bdfghklpqy
- j
- ```
- Letters on the same line are defined to be the same height. The first line is the shortest letters, the last line is the tallest letter.
- ## Input
- - A sequence of lower case letters
- - This may be a string or any data structure of characters
- ## Output
- - A sequence of the same letters in sorted order
- - This may be a string or any ordered data structure of characters. It does not need to match the input format (provided it is consistent between inputs)
- - For example, you may take input as an array of characters, and output as a string, provided this format does not change for different inputs
- - The sort does not need to be stable (letters that are the same height do not need to remain in the same order as the input, even if the input was already sorted)
- - The sort may be either ascending or descending
- ## Test cases
- Since the sort order can be either ascending or descending, and the sort does not need to be stable, most inputs will have many possible valid outputs. The test cases are in the format `"input" : ["valid", "outputs"]`. You may choose any of the valid outputs, but you must output only one of them.
- ```text
- "a" : ["a"]
- "aa" : ["aa"]
- "atibj" : ["atibj", "jbita"]
- "tick" : ["ctik", "kitc"]
- "now" : ["now", "nwo", "onw", "own", "wno", "won"]
- "just" : ["jtus", "jtsu", "sutj", "ustj"]
- "pjztyix" : ["xztipyj", "zxtipyj", "xztiypj", "zxtiypj", "jypitzx", "jypitxz", "jpyitzx", "jpyitxz"]
- ```
- # Now posted: [Sort letters by height](https://codegolf.codidact.com/posts/287324)
- ---
- Given a sequence of lower case letters, sort them into order of height.
- ## Heights
- The heights of letters are dependent on font, so for this challenge the height order to be used is as defined below:
- ```text
- acemnorsuvwxz
- t
- i
- bdfghklpqy
- j
- ```
- Letters on the same line are defined to be the same height. The first line is the shortest letters, the last line is the tallest letter.
- ## Input
- - A sequence of lower case letters
- - This may be a string or any data structure of characters
- ## Output
- - A sequence of the same letters in sorted order
- - This may be a string or any ordered data structure of characters. It does not need to match the input format (provided it is consistent between inputs)
- - For example, you may take input as an array of characters, and output as a string, provided this format does not change for different inputs
- - The sort does not need to be stable (letters that are the same height do not need to remain in the same order as the input, even if the input was already sorted)
- - The sort may be either ascending or descending
- ## Test cases
- Since the sort order can be either ascending or descending, and the sort does not need to be stable, most inputs will have many possible valid outputs. The test cases are in the format `"input" : ["valid", "outputs"]`. You may choose any of the valid outputs, but you must output only one of them.
- ```text
- "a" : ["a"]
- "aa" : ["aa"]
- "atibj" : ["atibj", "jbita"]
- "tick" : ["ctik", "kitc"]
- "now" : ["now", "nwo", "onw", "own", "wno", "won"]
- "just" : ["jtus", "jtsu", "sutj", "ustj"]
- "pjztyix" : ["xztipyj", "zxtipyj", "xztiypj", "zxtiypj", "jypitzx", "jypitxz", "jpyitzx", "jpyitxz"]
- ```
#7: Post edited
- Given a sequence of lower case letters, sort them into order of height.
- ## Heights
- The heights of letters are dependent on font, so for this challenge the height order to be used is as defined below:
- ```text
- acemnorsuvwxz
- t
- i
- bdfghklpqy
- j
- ```
- Letters on the same line are defined to be the same height. The first line is the shortest letters, the last line is the tallest letter.
- ## Input
- - A sequence of lower case letters
- - This may be a string or any data structure of characters
- ## Output
- - A sequence of the same letters in sorted order
- - This may be a string or any ordered data structure of characters. It does not need to match the input format (provided it is consistent between inputs)
- - For example, you may take input as an array of characters, and output as a string, provided this format does not change for different inputs
- - The sort does not need to be stable (letters that are the same height do not need to remain in the same order as the input, even if the input was already sorted)
- - The sort may be either ascending or descending
- ## Test cases
- Since the sort order can be either ascending or descending, and the sort does not need to be stable, most inputs will have many possible valid outputs. The test cases are in the format `"input" : ["valid", "outputs"]`. You may choose any of the valid outputs, but you must output only one of them.
- ```text
- "a" : ["a"]
- "aa" : ["aa"]
- "atibj" : ["atibj", "jbita"]
- "tick" : ["ctik", "kitc"]
- "now" : ["now", "nwo", "onw", "own", "wno", "won"]
- "just" : ["jtus", "jtsu", "sutj", "ustj"]
- ```
- Given a sequence of lower case letters, sort them into order of height.
- ## Heights
- The heights of letters are dependent on font, so for this challenge the height order to be used is as defined below:
- ```text
- acemnorsuvwxz
- t
- i
- bdfghklpqy
- j
- ```
- Letters on the same line are defined to be the same height. The first line is the shortest letters, the last line is the tallest letter.
- ## Input
- - A sequence of lower case letters
- - This may be a string or any data structure of characters
- ## Output
- - A sequence of the same letters in sorted order
- - This may be a string or any ordered data structure of characters. It does not need to match the input format (provided it is consistent between inputs)
- - For example, you may take input as an array of characters, and output as a string, provided this format does not change for different inputs
- - The sort does not need to be stable (letters that are the same height do not need to remain in the same order as the input, even if the input was already sorted)
- - The sort may be either ascending or descending
- ## Test cases
- Since the sort order can be either ascending or descending, and the sort does not need to be stable, most inputs will have many possible valid outputs. The test cases are in the format `"input" : ["valid", "outputs"]`. You may choose any of the valid outputs, but you must output only one of them.
- ```text
- "a" : ["a"]
- "aa" : ["aa"]
- "atibj" : ["atibj", "jbita"]
- "tick" : ["ctik", "kitc"]
- "now" : ["now", "nwo", "onw", "own", "wno", "won"]
- "just" : ["jtus", "jtsu", "sutj", "ustj"]
- "pjztyix" : ["xztipyj", "zxtipyj", "xztiypj", "zxtiypj", "jypitzx", "jypitxz", "jpyitzx", "jpyitxz"]
- ```
#6: Post edited
- Given a sequence of lower case letters, sort them into order of height.
- ## Heights
- The heights of letters are dependent on font, so for this challenge the height order to be used is as defined below:
- ```text
- acemnorsuvwxz
- t
- i
- bdfghklpqy
- j
- ```
- Letters on the same line are defined to be the same height. The first line is the shortest letters, the last line is the tallest letter.
- ## Input
- - A sequence of lower case letters
- - This may be a string or any data structure of characters
- ## Output
- - A sequence of the same letters in sorted order
- - This may be a string or any ordered data structure of characters. It does not need to match the input format (provided it is consistent between inputs)
- - For example, you may take input as an array of characters, and output as a string, provided this format does not change for different inputs
- - The sort does not need to be stable (letters that are the same height do not need to remain in the same order as the input, even if the input was already sorted)
- - The sort may be either ascending or descending
- ## Test cases
- Since the sort order can be either ascending or descending, and the sort does not need to be stable, most inputs will have many possible valid outputs. The test cases are in the format `"input" : ["valid", "outputs"]`. You may choose any of the valid outputs, but you must output only one of them.
- ```text
TODO: test cases- ```
- Given a sequence of lower case letters, sort them into order of height.
- ## Heights
- The heights of letters are dependent on font, so for this challenge the height order to be used is as defined below:
- ```text
- acemnorsuvwxz
- t
- i
- bdfghklpqy
- j
- ```
- Letters on the same line are defined to be the same height. The first line is the shortest letters, the last line is the tallest letter.
- ## Input
- - A sequence of lower case letters
- - This may be a string or any data structure of characters
- ## Output
- - A sequence of the same letters in sorted order
- - This may be a string or any ordered data structure of characters. It does not need to match the input format (provided it is consistent between inputs)
- - For example, you may take input as an array of characters, and output as a string, provided this format does not change for different inputs
- - The sort does not need to be stable (letters that are the same height do not need to remain in the same order as the input, even if the input was already sorted)
- - The sort may be either ascending or descending
- ## Test cases
- Since the sort order can be either ascending or descending, and the sort does not need to be stable, most inputs will have many possible valid outputs. The test cases are in the format `"input" : ["valid", "outputs"]`. You may choose any of the valid outputs, but you must output only one of them.
- ```text
- "a" : ["a"]
- "aa" : ["aa"]
- "atibj" : ["atibj", "jbita"]
- "tick" : ["ctik", "kitc"]
- "now" : ["now", "nwo", "onw", "own", "wno", "won"]
- "just" : ["jtus", "jtsu", "sutj", "ustj"]
- ```
#5: Post edited
- Given a sequence of lower case letters, sort them into order of height.
- ## Heights
- The heights of letters are dependent on font, so for this challenge the height order to be used is as defined below:
- ```text
aceozxnmruwsv- t
- i
yqpdfghklb- j
- ```
- Letters on the same line are defined to be the same height. The first line is the shortest letters, the last line is the tallest letter.
- ## Input
- - A sequence of lower case letters
- - This may be a string or any data structure of characters
- ## Output
- - A sequence of the same letters in sorted order
- - This may be a string or any ordered data structure of characters. It does not need to match the input format (provided it is consistent between inputs)
- - For example, you may take input as an array of characters, and output as a string, provided this format does not change for different inputs
- - The sort does not need to be stable (letters that are the same height do not need to remain in the same order as the input, even if the input was already sorted)
- - The sort may be either ascending or descending
- ## Test cases
- Since the sort order can be either ascending or descending, and the sort does not need to be stable, most inputs will have many possible valid outputs. The test cases are in the format `"input" : ["valid", "outputs"]`. You may choose any of the valid outputs, but you must output only one of them.
- ```text
- TODO: test cases
- ```
- Given a sequence of lower case letters, sort them into order of height.
- ## Heights
- The heights of letters are dependent on font, so for this challenge the height order to be used is as defined below:
- ```text
- acemnorsuvwxz
- t
- i
- bdfghklpqy
- j
- ```
- Letters on the same line are defined to be the same height. The first line is the shortest letters, the last line is the tallest letter.
- ## Input
- - A sequence of lower case letters
- - This may be a string or any data structure of characters
- ## Output
- - A sequence of the same letters in sorted order
- - This may be a string or any ordered data structure of characters. It does not need to match the input format (provided it is consistent between inputs)
- - For example, you may take input as an array of characters, and output as a string, provided this format does not change for different inputs
- - The sort does not need to be stable (letters that are the same height do not need to remain in the same order as the input, even if the input was already sorted)
- - The sort may be either ascending or descending
- ## Test cases
- Since the sort order can be either ascending or descending, and the sort does not need to be stable, most inputs will have many possible valid outputs. The test cases are in the format `"input" : ["valid", "outputs"]`. You may choose any of the valid outputs, but you must output only one of them.
- ```text
- TODO: test cases
- ```
#4: Post edited
- Given a sequence of lower case letters, sort them into order of height.
- ## Heights
- The heights of letters are dependent on font, so for this challenge the height order to be used is as defined below:
- ```text
- aceozxnmruwsv
- t
- i
- yqpdfghklb
- j
- ```
- Letters on the same line are defined to be the same height. The first line is the shortest letters, the last line is the tallest letter.
- ## Input
- - A sequence of lower case letters
- - This may be a string or any data structure of characters
- ## Output
- - A sequence of the same letters in sorted order
- This may be a string or any ordered data structure of characters.- - The sort does not need to be stable (letters that are the same height do not need to remain in the same order as the input, even if the input was already sorted)
- - The sort may be either ascending or descending
- ## Test cases
- Since the sort order can be either ascending or descending, and the sort does not need to be stable, most inputs will have many possible valid outputs. The test cases are in the format `"input" : ["valid", "outputs"]`. You may choose any of the valid outputs, but you must output only one of them.
- ```text
- TODO: test cases
- ```
- Given a sequence of lower case letters, sort them into order of height.
- ## Heights
- The heights of letters are dependent on font, so for this challenge the height order to be used is as defined below:
- ```text
- aceozxnmruwsv
- t
- i
- yqpdfghklb
- j
- ```
- Letters on the same line are defined to be the same height. The first line is the shortest letters, the last line is the tallest letter.
- ## Input
- - A sequence of lower case letters
- - This may be a string or any data structure of characters
- ## Output
- - A sequence of the same letters in sorted order
- - This may be a string or any ordered data structure of characters. It does not need to match the input format (provided it is consistent between inputs)
- - For example, you may take input as an array of characters, and output as a string, provided this format does not change for different inputs
- - The sort does not need to be stable (letters that are the same height do not need to remain in the same order as the input, even if the input was already sorted)
- - The sort may be either ascending or descending
- ## Test cases
- Since the sort order can be either ascending or descending, and the sort does not need to be stable, most inputs will have many possible valid outputs. The test cases are in the format `"input" : ["valid", "outputs"]`. You may choose any of the valid outputs, but you must output only one of them.
- ```text
- TODO: test cases
- ```
#3: Post edited
- Given a sequence of lower case letters, sort them into order of height.
- ## Heights
- The heights of letters are dependent on font, so for this challenge the height order to be used is as defined below:
- ```text
- aceozxnmruwsv
- t
- i
- yqpdfghklb
- j
- ```
- Letters on the same line are defined to be the same height. The first line is the shortest letters, the last line is the tallest letter.
- ## Input
- - A sequence of lower case letters
- - This may be a string or any data structure of characters
- ## Output
- - A sequence of the same letters in sorted order
- - This may be a string or any ordered data structure of characters.
- - The sort does not need to be stable (letters that are the same height do not need to remain in the same order as the input, even if the input was already sorted)
- - The sort may be either ascending or descending
- ## Test cases
Since the sort order can be either ascending or descending, and the sort does not need to be stable, most inputs will have many possible valid outputs. The test cases are in the format `input : ["valid", "outputs"]`. You may choose any of the valid outputs, but you must output only one of them.- ```text
- TODO: test cases
- ```
- Given a sequence of lower case letters, sort them into order of height.
- ## Heights
- The heights of letters are dependent on font, so for this challenge the height order to be used is as defined below:
- ```text
- aceozxnmruwsv
- t
- i
- yqpdfghklb
- j
- ```
- Letters on the same line are defined to be the same height. The first line is the shortest letters, the last line is the tallest letter.
- ## Input
- - A sequence of lower case letters
- - This may be a string or any data structure of characters
- ## Output
- - A sequence of the same letters in sorted order
- - This may be a string or any ordered data structure of characters.
- - The sort does not need to be stable (letters that are the same height do not need to remain in the same order as the input, even if the input was already sorted)
- - The sort may be either ascending or descending
- ## Test cases
- Since the sort order can be either ascending or descending, and the sort does not need to be stable, most inputs will have many possible valid outputs. The test cases are in the format `"input" : ["valid", "outputs"]`. You may choose any of the valid outputs, but you must output only one of them.
- ```text
- TODO: test cases
- ```
#2: Post edited
- Given a sequence of lower case letters, sort them into order of height.
- ## Heights
- The heights of letters are dependent on font, so for this challenge the height order to be used is as defined below:
- ```text
- aceozxnmruwsv
it- yqpdfghklb
- j
- ```
- Letters on the same line are defined to be the same height. The first line is the shortest letters, the last line is the tallest letter.
- ## Input
- - A sequence of lower case letters
- - This may be a string or any data structure of characters
- ## Output
- - A sequence of the same letters in sorted order
- - This may be a string or any ordered data structure of characters.
- The sort does not need to be stable (letters that are the same height do not need to remain in the same order as the input)- - The sort may be either ascending or descending
- ## Test cases
- Since the sort order can be either ascending or descending, and the sort does not need to be stable, most inputs will have many possible valid outputs. The test cases are in the format `input : ["valid", "outputs"]`. You may choose any of the valid outputs, but you must output only one of them.
- ```text
- TODO: test cases
- ```
- Given a sequence of lower case letters, sort them into order of height.
- ## Heights
- The heights of letters are dependent on font, so for this challenge the height order to be used is as defined below:
- ```text
- aceozxnmruwsv
- t
- i
- yqpdfghklb
- j
- ```
- Letters on the same line are defined to be the same height. The first line is the shortest letters, the last line is the tallest letter.
- ## Input
- - A sequence of lower case letters
- - This may be a string or any data structure of characters
- ## Output
- - A sequence of the same letters in sorted order
- - This may be a string or any ordered data structure of characters.
- - The sort does not need to be stable (letters that are the same height do not need to remain in the same order as the input, even if the input was already sorted)
- - The sort may be either ascending or descending
- ## Test cases
- Since the sort order can be either ascending or descending, and the sort does not need to be stable, most inputs will have many possible valid outputs. The test cases are in the format `input : ["valid", "outputs"]`. You may choose any of the valid outputs, but you must output only one of them.
- ```text
- TODO: test cases
- ```
#1: Initial revision
Sort letters by height
Given a sequence of lower case letters, sort them into order of height. ## Heights The heights of letters are dependent on font, so for this challenge the height order to be used is as defined below: ```text aceozxnmruwsv it yqpdfghklb j ``` Letters on the same line are defined to be the same height. The first line is the shortest letters, the last line is the tallest letter. ## Input - A sequence of lower case letters - This may be a string or any data structure of characters ## Output - A sequence of the same letters in sorted order - This may be a string or any ordered data structure of characters. - The sort does not need to be stable (letters that are the same height do not need to remain in the same order as the input) - The sort may be either ascending or descending ## Test cases Since the sort order can be either ascending or descending, and the sort does not need to be stable, most inputs will have many possible valid outputs. The test cases are in the format `input : ["valid", "outputs"]`. You may choose any of the valid outputs, but you must output only one of them. ```text TODO: test cases ```