单选题:For code below, the result s would be?
For code below, the result s would be? @[A](2)
```Java
String s = String.format("2.1 can be rounded as %i\n", Math.round(2.1));
```
A. Compile error
B. 2.1 can be rounded as 2
C. 2.1 can be rounded as 2.1
D. Run-time exception
A.Compile error
B.2.1 can be rounded as 2
C.2.1 can be rounded as 2.1
D.Run-time exception
答案:A
```Java
String s = String.format("2.1 can be rounded as %i\n", Math.round(2.1));
```
A. Compile error
B. 2.1 can be rounded as 2
C. 2.1 can be rounded as 2.1
D. Run-time exception
A.Compile error
B.2.1 can be rounded as 2
C.2.1 can be rounded as 2.1
D.Run-time exception
答案:A