module second_counter(EN,clk,second_data1,second_data0,EO);

output [3:0] second_data1,second_data0;
output EO;
input  clk,EN;

reg [3:0] second_data1,second_data0;
reg EO;

always @(posedge clk)
begin
  if(EN == 1'b1)
    begin
	  if(second_data0 < 4'b1001)
		second_data0 <= second_data0 + 4'b1;
	  else
	  begin
		EO <= 1'b0;
		second_data0 <= 4'b0;
		if(second_data1 < 4'b0101)
		  second_data1 <= second_data1 + 4'b1;
		else
		begin
		  second_data1 <= 4'b0;
		  EO <= 1'b1;
		end
	  end
	end
end
endmodule