fork download
  1. #!/bin/bash
  2. s="false,false,false,true"
  3. sed -E ':a;s/(,|^)false(,|$)/\1N\2/;ta; :b;s/(,|^)true(,|$)/\1Y\2/;tb' <<< "$s"
Success #stdin #stdout 0s 4504KB
stdin
Standard input is empty
stdout
N,N,N,Y