Pregunta de entrevista de Publicis Sapient

2 simple coding question of arrays on hackerrank. In technical interviews round oops concept, real time problem solution using oops concept, java , some basic coding question