单项选择题

下面这个程序段的时间复杂度是( )。
for (i=1; i<n; i++)
y=y+3;
for (j=0;j<=(2*n);j++)
x++;

A.O(10g2n)
B.O(n)
C.O(nlog2n)
D.O(n2)