more versatile with input