해커랭크 썸네일형 리스트형 [Hackerrank] Scope Objective Today we're discussing scope. Check out the Tutorial tab for learning materials and an instructional video! The absolute difference between two integers, and , is written as . The maximum absolute difference between two integers in a set of positive integers, , is the largest absolute difference between any two integers in . The Difference class is started for you in the editor. It has.. 더보기 [Hackerrank] Abstract Classes Objective Today, we will extend what we learned yesterday about Inheritance to Abstract Classes. Because this is a very specific object oriented concept, submissions are limited to the few languages that use this construct. Check out the Tutorial tab for learning materials and an instructional video. Task Given a Book class and a Solution class, write a MyBook class that does the following: Inhe.. 더보기 [Hackerrank] Ingeritance Objective Today, we're delving into Inheritance. Check out the attached tutorial for learning materials and an instructional video. Task You are given two classes, Person and Student, where Person is the base class and Student is the derived class. Completed code for Person and a declaration for Student are provided for you in the editor. Observe that Student inherits all the properties of Perso.. 더보기 [Hackerrank] Binary Numbers Objective Today, we're working with binary numbers. Check out the Tutorial tab for learning materials and an instructional video! Task Given a base- integer, , convert it to binary (base-). Then find and print the base- integer denoting the maximum number of consecutive 's in 's binary representation. When working with different bases, it is common to show the base as a subscript. Example The bi.. 더보기 [Hackerrank] Recursion 3 Objective Today, we are learning about an algorithmic concept called recursion. Check out the Tutorial tab for learning materials and an instructional video. Recursive Method for Calculating Factorial Function Description Complete the factorial function in the editor below. Be sure to use recursion. factorial has the following paramter: int n: an integer Returns int: the factorial of n Note: If .. 더보기 [Hackerrank] Dictionaries and Maps Objective Today, we're learning about Key-Value pair mappings using a Map or Dictionary data structure. Check out the Tutorial tab for learning materials and an instructional video! Task Given n names and phone numbers, assemble a phone book that maps friends' names to their respective phone numbers. You will then be given an unknown number of names to query your phone book for. For each name qu.. 더보기 [Hackerrank] Arrays Objective Today, we will learn about the Array data structure. Check out the Tutorial tab for learning materials and an instructional video. Task Given an array, A, of N integers, print A's elements in reverse order as a single line of space-separated numbers. Example A = [1, 2, 3, 4] Print 4 3 2 1. Each integer is separated by one space. Input Format The first line contains an integer, N (the s.. 더보기 [Hackerrank] Let's Review Objective Today we will expand our knowledge of strings, combining it with what we have already learned about loops. Check out the Tutorial tab for learning materials and an instructional video. Task Given a string, S , of length N that is indexed from 0 to N - 1, print its even-indexed and odd-indexed characters as 2 space-separated strings on a single line (see the Sample below for more detail.. 더보기 이전 1 다음