module assignment(Q,clk,rst);
input clk,rst;
output [2:0]Q;
always @(posedge clk)
begin
if(rst);
begin
Q<=3'b000;
end
else()
begin
case(Q)3'b000: Q<=3'b001;
3'b001: Q<=3'b010;
3'b010: Q<=3'b100;
3'b100: Q<=3'b110;
default: Q<=3'b000;
endcase
end
end
endmodule
i'm getting this error in above program.
"near "else": syntax error, unexpected else"
can anyone help me?
thanks in advance