[Java daily question] 20170119, java20170119
20170118 for problem resolution, click "Java daily question" 20170119 "below today's question to view the problem (The problem is resolved at the beginning of the public account, public ID: weknow619)
Package Jan2017; import java. util. arrays; import java. util. list; public class Ques0119 {public static void main (String [] arg) {List <String> list = Arrays. asList ("1", "2"); for (String str: toArray (list) {System. out. println (str) ;}} public static <T> T [] toArray (List <T> list) {T [] t = (T []) new Object [list. size ()]; for (int I = 0, s = list. size (); I <s; I ++) {t [I] = list. get (I) ;}return t ;}}
Today's question:
Can the main program properly run and output results? (Click "[Java daily question] 20170119" below to view issue resolution 20170118)
Questions originally published on the public account and short book: [Java daily question] 20170119, [Java daily question] 20170119 (you can also scan the Avatar QR code to view)
The weknow team has activated the authentication and has answered questions. If you have any questions, you can also consult. Click the answer to find me !!