---
title: "Discussion on \"Positive or Negative Number\" | Hashnode"
description: "Discussion on \"Positive or Negative Number\". Explanation :\nStep 1: Take a number from the user by using the Scanner class object.\nStep 2: If the given number is < 0 then it is a negative number otherwise, it is a positive number.\nJava Code :\n//postive or negative\n\nimport java.util.Scanner;\n\npub..."
url: "https://hashnode.com/posts/positive-or-negative-number/63a7c6b21ef6c13995762433"
---

[Feed](https://hashnode.com/feed) /

Discussion

# [Positive or Negative Number](https://smartcookie.hashnode.dev/positive-or-negative-number?utm_source=hashnode&utm_medium=feed)

Explanation : Step 1: Take a number from the user by using the Scanner class object. Step 2: If the given number is < 0 then it is a negative number otherwise, it is a positive number. Java Code : //postive or negative import java.util.Scanner; pub...

Dec 25, 2022 · 1 min read · smartcookie.hashnode.dev  
Read the article

-   [#positive-or-negative-numbers-in-java](https://hashnode.com/tag/positive-or-negative-numbers-in-java)
-   [#java](https://hashnode.com/tag/java)
-   [#java-programming](https://hashnode.com/tag/java-programming)
-   [#java-interview-questions](https://hashnode.com/tag/java-interview-questions)
-   [#java-interview-points](https://hashnode.com/tag/java-interview-points)

## Written by

[Madhu Palle](https://hashnode.com/@smartcookie)

@smartcookie · INDIA

  
[View profile](https://hashnode.com/@smartcookie)

Go with the flow

IIIT - N Software Geek. Startup Enthusiast. Build for the Future.

## Responses

Markdown supported · ⌘↵ to post

No responses yet.
