write code to dynamic add input lines.