Skip to content

Added Java Problem Solution for Stdin and Stdout at Hackerrank Platform #1262

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Open
wants to merge 5 commits into
base: master
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
22 changes: 22 additions & 0 deletions Hackerrank/Solution.java
Original file line number Diff line number Diff line change
@@ -0,0 +1,22 @@

/*
* https://www.hackerrank.com/challenges/java-stdin-and-stdout-1/problem
*/

import java.util.Scanner;

public class Solution {

public static void main(String[] args) {
Scanner scan = new Scanner(System.in);
int i = scan.nextInt();
scan.nextLine(); // Consume the newline character after reading the int
double d = scan.nextDouble();
scan.nextLine(); // Consume the newline character after reading the double
String s = scan.nextLine();

System.out.println("String: " + s);
System.out.println("Double: " + d);
System.out.println("Int: " + i);
}
}
1 change: 1 addition & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -102,6 +102,7 @@ In this repository, you can find the solutions (as source code) for the problems
| [Nauman Chaudhary](https://github.com/nauman-chaudhary) <br> <img src="https://github.com/nauman-chaudhary.png" width="100" height="100"> | Pakistan | Python | |
| [Gourav Rusiya](https://github.com/GouravRusiya30) <br> <img src="https://github.com/GouravRusiya30.png" width="100" height="100"> | India | Java | https://www.hackerrank.com/gouravrusiya786 |
| [Trushita Maurya](https://github.com/trushita23) <br> <img src="https://github.com/trushita23.png" width="100" height="100"> | India | Java
| [Syed Khaja Moinuddin](https://github.com/s-yed) <br> <img src="https://github.com/S-YED.png" width="100" height="100"> | India | Java |
### License

[![MIT Licence](https://badges.frapsoft.com/os/mit/mit.svg?v=103)](https://github.com/ows-ali/Hacktoberfest/blob/master/LICENSE)
47 changes: 22 additions & 25 deletions Udacity/BookListingAndroidApp/README.md
Original file line number Diff line number Diff line change
@@ -1,31 +1,28 @@
## BookListingApp
Project which comes under Udacity Android Basics Nanodegree Program
# BookListingApp
Project under Udacity Android Basics Nanodegree Program

## Table of Contents
- [Project Overview](#project-overview)
- [Why This Project?](#why-this-project)
- [What Will I Learn?](#what-will-i-learn)
- [Requirements](#requirements)
- [Setup Instructions](#setup-instructions)
- [Final Output - Screenshots](#final-output---screenshots)
- [Download](#download)
- [Contribution Guidelines](#contribution-guidelines)

## Project Overview
The goal is to design and create the structure of a Book Listing app which would allow a user to get a list of published books on a given topic. You will be using the google books api in order to fetch results and display them to the user.
The goal is to design and create the structure of a Book Listing app that allows a user to get a list of published books on a given topic. You will use the Google Books API to fetch results and display them to the user.

## Why this project?
I learned about the web and about how to get data from an api. I also learned how to parse that data and display it to a user. This project gives me the ability to practice those skills, which will be key in developing any app which makes use of a backend server, real time data, or interactions over the internet.
## Why This Project?
This project helps you learn about the web and how to get data from an API. You will also learn how to parse that data and display it to a user. This project is key for developing any app that makes use of a backend server, real-time data, or interactions over the internet.

## What will I learn?
This project is about combining various ideas and skills we’ve been practicing throughout the course. They include:

1. Fetching data from an API
2. Using an AsyncTask
3. Parsing a JSON response
4. Creating a list based on that data and displaying it to the user.
## What Will I Learn?
This project combines various ideas and skills practiced throughout the course, including:
- Fetching data from an API
- Using an AsyncTask
- Parsing a JSON response
- Creating a list based on that data and displaying it to the user

## Requirements
To achieve this, I'll make use of the [Google Books API](https://developers.google.com/books/docs/v1/getting_started#intro). This is a well-maintained API which returns information in a JSON format.
An example query that we found useful was :

https://www.googleapis.com/books/v1/volumes?q=android&maxResults=1

## Final Output - Screenshots

Screen 1 |Screen 2
:--------------------------------:|:--------------------------------:
![](app/screenshots/screen1.png) |![](app/screenshots/screen2.png)

## Download
You can download the apk here [BookListingApp](../../raw/master/app/screenshots/app-debug.apk)
To achieve this, we'll use the [Google Books API](https://developers.google.com/books/docs/v1/getting_started#intro). This is a well-maintained API that returns information in JSON format.