Looking for Programare orientata pe obiecte (POB) test answers and solutions? Browse our comprehensive collection of verified answers for Programare orientata pe obiecte (POB) at elearning.unitbv.ro.
Get instant access to accurate answers and detailed explanations for your course questions. Our community-driven platform helps students succeed!
String-urile x si y sunt identice
String data1 = LocalDate.of(2013, 11, 18).toString();
String data2 = LocalDate.of(2038, 1, 1).toString();
String x = data1.replaceAll("[1-]", "");
String y = data2.replaceAll("-", "").substring(0,4);
Selectati ce string-uri se potrivesc cu expresia de mai jos folosind functia matches().
String regex = "[[[[a]b]c]d]e";
Selectati ce string-uri se potrivesc cu expresia de mai jos folosind functia find().
String regex = "[^^]";
Selectati ce string-uri se potrivesc cu expresia de mai jos folosind functia find().
String regex = "[^*]";
Care este rezultatul urmatoarei secvente de cod?
String text = "abcde123abcde456";
text = text.replaceAll("\\d{2}", "x");
String[] parts = text.split("\\d+");
System.out.println(text + " " +parts.length);
Selectati ce string-uri se potrivesc cu expresia de mai jos folosind functia matches().
String regex = "(B(AB|A){1,}D){1,}";
Selectati ce string-uri se potrivesc cu expresia de mai jos folosind functia find().
String regex = "..";
Folosind functia find() si expresia de mai jos, se va detecta orice sir de caracter dat, indiferent de caracterele sale.
String regex = "";
In acest caz, variabila sir2 este egala cu "cccbbc", inlocuind toate aparitiile caracterelor 'a' si 'c' cu caracterul 'c'
String sir1 = "aaabbc";
String sir2 = sir1.replaceAll("[^ac]", "c");
Care este rezultatul urmatoarei secvente de cod?
String sir1 = "aaabbc";
String sir2 = sir1.replaceAll("", "e");
System.out.println(sir2);
Get Unlimited Answers To Exam Questions - Install Crowdly Extension Now!