Menu
Question Index
...

import java.nio.*;

public class Buffers {
    public static void main(String[] args) {
        FloatBuffer floatBuf = FloatBuffer.allocate(5);
        
        //LINE A

    }
}
Which of the following is required to get compilation error to the above program?


floatBuf.put(1);
floatBuf.put(1f);
floatBuf.put((float) 1.0);
floatBuf.put(1.0f);
All of the above
None of the above

Doubts

Problems

Topic: Other Advanced Topics In Java

Read this topic
Take test on this topic

0
Wrong
Score more than 2 points

© meritcampus 2019

All Rights Reserved.

Open In App