05AB1E, (削除) 20 (削除ここまで) (削除) 18 (削除ここまで) (削除) 16 (削除ここまで) 14 bytes
S¢Z≠sË*sZ¢≠SË*
The program is essentially divided into 2 parts where the goal of the first part is to do the actual task and the goal of the second part is to use the same functions as the first part without altering the result.
Explanation (first part)
S # push input split into list of chars
¢ # count the occurrence of each char in input
Z≠ # check that the max count is not 1
sË # check if all counts are equal
* # multiply
Explanation (second part)
s # swap input to top of stack
Z¢ # count the number of occurrences of the largest element
≠ # check that the count isn't 1
SË # split into list and check that each element are equal (always true)
* # multiply (as thisit is alwayswith 1, the original result is left unchanged)
05AB1E, (削除) 20 (削除ここまで) (削除) 18 (削除ここまで) (削除) 16 (削除ここまで) 14 bytes
S¢Z≠sË*sZ¢≠SË*
The program is essentially divided into 2 parts where the goal of the first part is to do the actual task and the goal of the second part is to use the same functions as the first part without altering the result.
Explanation (first part)
S # push input split into list of chars
¢ # count the occurrence of each char in input
Z≠ # check that the max count is not 1
sË # check if all counts are equal
* # multiply
Explanation (second part)
s # swap input to top of stack
Z¢ # count the number of occurrences of the largest element
≠ # check that the count isn't 1
SË # split into list and check that each element are equal (always true)
* # multiply (as this is always 1 the original result is unchanged)
05AB1E, (削除) 20 (削除ここまで) (削除) 18 (削除ここまで) (削除) 16 (削除ここまで) 14 bytes
S¢Z≠sË*sZ¢≠SË*
The program is essentially divided into 2 parts where the goal of the first part is to do the actual task and the goal of the second part is to use the same functions as the first part without altering the result.
Explanation (first part)
S # push input split into list of chars
¢ # count the occurrence of each char in input
Z≠ # check that the max count is not 1
sË # check if all counts are equal
* # multiply
Explanation (second part)
s # swap input to top of stack
Z¢ # count the number of occurrences of the largest element
≠ # check that the count isn't 1
SË # split into list and check that each element are equal (always true)
* # multiply (as it is with 1, the original result is left unchanged)
05AB1E, (削除) 20 (削除ここまで) (削除) 18 (削除ここまで) 16(削除) 16 (削除ここまで) 14 bytes
IS¢Z≠Ë*sIS¢Z≠sË*S¢Z≠sË*sZ¢≠SË*
The program is essentially divided into 2 parts where the goal of the secondfirst part is to do the actual task and the goal of the firstsecond part is to use the same functions as the secondfirst part while leaving the stack in a state whichwithout altering the second part can work withresult.
Explanation (first part)
ISS # push input split into list of chars
¢ # count the occurrence of each char in input
Z≠ # check that the max count is not 1
Ë sË # check if all elementscounts are equal (always true)
* # multiply with list of occurrences
s # swap the input to the top of the stack
Explanation (second part)
ISs # pushswap input split intoto listtop of charsstack
¢ Z¢ # count occurrencesthe number of eachoccurrences charof inthe inputlargest element
Z≠≠ # check that the max count is notisn't 1
sËSË # checksplit thatinto thelist countand ofcheck allthat elementseach element are equal (always true)
* # multiply (as this is always 1 the original result is unchanged)
05AB1E, (削除) 20 (削除ここまで) (削除) 18 (削除ここまで) 16 bytes
IS¢Z≠Ë*sIS¢Z≠sË*
The program is essentially divided into 2 parts where the goal of the second part is to do the actual task and the goal of the first part is to use the same functions as the second part while leaving the stack in a state which the second part can work with.
Explanation (first part)
IS # push input split into list of chars
¢ # count the occurrence of each char in input
Z≠ # check that the max count is not 1
Ë # check if all elements are equal (always true)
* # multiply with list of occurrences
s # swap the input to the top of the stack
Explanation (second part)
IS # push input split into list of chars
¢ # count occurrences of each char in input
Z≠ # check that the max count is not 1
sË # check that the count of all elements are equal * # multiply
05AB1E, (削除) 20 (削除ここまで) (削除) 18 (削除ここまで) (削除) 16 (削除ここまで) 14 bytes
S¢Z≠sË*sZ¢≠SË*
The program is essentially divided into 2 parts where the goal of the first part is to do the actual task and the goal of the second part is to use the same functions as the first part without altering the result.
Explanation (first part)
S # push input split into list of chars
¢ # count the occurrence of each char in input
Z≠ # check that the max count is not 1
sË # check if all counts are equal
* # multiply
Explanation (second part)
s # swap input to top of stack
Z¢ # count the number of occurrences of the largest element
≠ # check that the count isn't 1
SË # split into list and check that each element are equal (always true)
* # multiply (as this is always 1 the original result is unchanged)
05AB1E, (削除) 20 (削除ここまで) 18(削除) 18 (削除ここまで) 16 bytes
IS¢¤X›Ë*sIS¢¤X›sË*IS¢Z≠Ë*sIS¢Z≠sË*
The program is essentially divided into 2 parts where the goal of the second part is to do the actual task and the goal of the first part is to use the same functions as the second part while leaving the stack in a state which the second part can work with.
Explanation (first part)
IS # push input split into list of chars
¢ # count the occurrence of each char in input
¤X›Z≠ # check if the count ofthat the lastmax elementcount is greater thannot 1
Ë # check if all elements are equal (always true)
* # multiply with list of occurrences
s # swap the input to the top of the stack
Explanation (second part)
IS # push input split into list of chars
¢ # count occurrences of each char in input
¤X›Z≠ # check if the count ofthat the lastmax elementcount is greater thannot 1
sË # check that the count of all elements are equal
* # multiply
05AB1E, (削除) 20 (削除ここまで) 18 bytes
IS¢¤X›Ë*sIS¢¤X›sË*
The program is essentially divided into 2 parts where the goal of the second part is to do the actual task and the goal of the first part is to use the same functions as the second part while leaving the stack in a state which the second part can work with.
Explanation (first part)
IS # push input split into list of chars
¢ # count the occurrence of each char in input
¤X› # check if the count of the last element is greater than 1
Ë # check if all elements are equal (always true)
* # multiply with list of occurrences
s # swap the input to the top of the stack
Explanation (second part)
IS # push input split into list of chars
¢ # count occurrences of each char in input
¤X› # check if the count of the last element is greater than 1
sË # check that the count of all elements are equal
* # multiply
05AB1E, (削除) 20 (削除ここまで) (削除) 18 (削除ここまで) 16 bytes
IS¢Z≠Ë*sIS¢Z≠sË*
The program is essentially divided into 2 parts where the goal of the second part is to do the actual task and the goal of the first part is to use the same functions as the second part while leaving the stack in a state which the second part can work with.
Explanation (first part)
IS # push input split into list of chars
¢ # count the occurrence of each char in input
Z≠ # check that the max count is not 1
Ë # check if all elements are equal (always true)
* # multiply with list of occurrences
s # swap the input to the top of the stack
Explanation (second part)
IS # push input split into list of chars
¢ # count occurrences of each char in input
Z≠ # check that the max count is not 1
sË # check that the count of all elements are equal
* # multiply