When you write an action listener class for a JButton component, it must a method named buttonclicked implement the ActionListener interface have a method named actionPerformed which must take an argument of the ActionEvent type Both B and C What is the value of str after the following code has been executed? string str: string sourcestr = “Hey diddle, diddle, the cat and the fiddle”: str = sourceStr.substring (12, 17): diddl didd lddle diddle The GridLayout manager limits each cell to only one component. To put two or more components in a cell you can nest panels inside the cells, and add other components to the panels resize the cells so they can hold more resize the components to fit in the cell The statement is false, the GridLayout manager does not have this restriction. What will be the tokens in the following statement? stringTokenizer strToken = new StringTokenizer (“123-456-7890”, “-“, true): 123, 456, 7890, and- – 123, 456, and 7890 None of the above What will be printed after the following code is executed? string str” = “abc456” int m = 0: while (m
Expert Answer