Skip to content

Partition #8

@ChillBroYo

Description

@ChillBroYo

Write code to partition a list around a central value, such that for a certain value x, all the values less than it come before all the values that come after it. Do this as fast as possible in a singly linked list.
Example input: 3 -> 5 -> 8 -> 5 -> 10 -> 2 -> 1
Example output: 3 -> 1 -> 2 -> 10 -> 5 -> 5 -> 8

Metadata

Metadata

Assignees

Labels

No labels
No labels

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions