<< Prev Question Next Question >>

Question 50/70

You are developing a banking module. You have developed a class named ccMask that has a maskcc method.
Given the code fragment:

You must ensure that the maskcc method returns a string that hides all digits of the credit card number except the four last digits (and the hyphens that separate each group of four digits).
Which two code fragments should you use at line n1, independently, to achieve this requirement?

LEAVE A REPLY

Your email address will not be published. Required fields are marked *

Question List (70q)
Question 1: Given the code fragment: (Exhibit) What is the result?...
Question 2: Given: (Exhibit) What is the result? (Exhibit)...
Question 3: Given the content of three files: (Exhibit) Which statement ...
Question 4: Given the code fragment: (Exhibit) Which three lines fail to...
Question 5: Given the code fragments: (Exhibit) Which code fragment, whe...
Question 6: Given: (Exhibit) What is the result? (Exhibit)...
Question 7: Given the code fragment: (Exhibit) And given the requirement...
Question 8: Given the code fragment: (Exhibit) Which two modifications s...
Question 9: Given: (Exhibit) Which statement is true?...
Question 10: Given: (Exhibit) What is the result?...
Question 11: Given the following two classes: (Exhibit) How should you wr...
Question 12: You are asked to develop a program for a shopping applicatio...
Question 13: Given the code fragment from three files: (Exhibit) Which co...
Question 14: Given the definitions of the MyString class and the Test cla...
Question 15: Given the code fragment: int[] array = {1, 2, 3, 4, 5}; And ...
Question 16: Given the code fragment: (Exhibit) Which option represents t...
Question 17: Which three statements describe the object-oriented features...
Question 18: Given the code fragment: (Exhibit) What is the result?...
Question 19: Given: (Exhibit) What is the result?...
Question 20: Given the code fragment: (Exhibit) Which two modifications, ...
Question 21: Which three are advantages of the Java exception mechanism?...
Question 22: Given the following code: (Exhibit) What is the output?...
Question 23: Given the code fragment: (Exhibit) Which code fragment, when...
Question 24: Given: (Exhibit) What is the result?...
Question 25: Given the code fragment: (Exhibit) Which option can replace ...
Question 26: Given the code fragment: (Exhibit) What is the result?...
Question 27: Given the code fragment: (Exhibit) What is the result?...
Question 28: Given: (Exhibit) Which option enables the code to compile? (...
Question 29: Given the code fragment: (Exhibit) What is the result?...
Question 30: Given the code fragment: (Exhibit) What is the result?...
Question 31: Given the code fragment: (Exhibit) Which code fragment print...
Question 32: Given: (Exhibit) What is the result?...
Question 33: Given the code fragment: (Exhibit) What is the result?...
Question 34: Given the code fragment: (Exhibit) What is the result if the...
Question 35: Given: (Exhibit) And given the commands: javac Test.Java Jav...
Question 36: Given: (Exhibit) What is the result?...
Question 37: Given the following class declarations: public abstract clas...
Question 38: Given: (Exhibit) What is the result?...
Question 39: Given the code fragment: (Exhibit) Which two modifications, ...
Question 40: Given: (Exhibit) And given the code fragment: (Exhibit) What...
Question 41: Given: (Exhibit) What is the result?...
Question 42: Given the following class: (Exhibit) And given the following...
Question 43: Given the code fragment: (Exhibit) Which three code fragment...
Question 44: What is the name of the Java concept that uses access modifi...
Question 45: Given: (Exhibit) What is the result?...
Question 46: Given the code fragment: (Exhibit) What is the result?...
Question 47: Given the following code for a Planet object: (Exhibit) What...
Question 48: Given the code fragment: (Exhibit) Which modification enable...
Question 49: Given the code fragment: (Exhibit) Which code fragment, when...
Question 50: You are developing a banking module. You have developed a cl...
Question 51: Given the code fragment: (Exhibit) What is the result?...
Question 52: Given the following array: (Exhibit) Which two code fragment...
Question 53: Given: (Exhibit) What is the result? (Exhibit)...
Question 54: Given: (Exhibit) How many MarkList instances are created in ...
Question 55: Given the following main method: (Exhibit) What is the resul...
Question 56: Given: (Exhibit) What is the result?...
Question 57: Given the code fragment: (Exhibit) What is the result?...
Question 58: Given: (Exhibit) What is the result?...
Question 59: Given the code from the Greeting.Java file: (Exhibit) Which ...
Question 60: Given the code fragment: (Exhibit) What is the result?...
Question 61: Which statement best describes encapsulation?...
Question 62: Given: (Exhibit) Which code fragment should you use at line ...
Question 63: Given the code fragment: (Exhibit) What is the result?...
Question 64: Given the following code: (Exhibit) What are the values of e...
Question 65: Which statement is true about Java byte code?...
Question 66: Given the code fragment: (Exhibit) What is the result?...
Question 67: Given the code fragment: (Exhibit) What is the result?...
Question 68: Given the code fragment: (Exhibit) Which modification enable...
Question 69: Given the code fragment: (Exhibit) Which code fragment, when...
Question 70: Given the code fragment: (Exhibit) Assume that the system da...