Skip to content

ValleysToPeaks ​

Every valley 01 swapped for a peak 10, and a trailing 0 made a 1.

ValleysToPeaks(BinaryWord)Every valley 01 swapped for a peak 10, and a trailing 0 made a 1.
Typed signatures
TypePackageApplies
(binary_word) -> binary_wordcombinatoricsalways

Domain: Combinatorial maps

Details
  • Takes a BinaryWord and returns a BinaryWord — a typed map, so a wrong carrier is a type error rather than a wrong answer.
  • FindStat's Mp00234. Lossy: 01 and 10 both give 10.

Examples

Basic #

the binary word 0110001100

live ↗
InValleysToPeaks(BinaryWord⁡([0,1,1,0,0]))\mathrm{ValleysToPeaks}({\operatorname{BinaryWord}}([0, 1, 1, 0, 0]))OutBinaryWord⁡([1,0,1,0,1]){\operatorname{BinaryWord}}([1, 0, 1, 0, 1])
About
Examples1
CrosswalkFindStat