The cleverness inside coreutils is mostly around choosing effective ways to interface with the kernel, e.g. using copy_file_range() instead of read()/write() to avoid having to copy the data into userspace.
It's more a software engineering endeavour instead of computer science.
Maybe I’m misunderstanding but what do data structures and algorithms have to do with CLI tools?
Don't CLI tools use data structures and algorithms?
Not massively. I mean, an array is a data structure and looping through it is an algorithm, but that’s a bit basic even for a 101 DSA course.