URI Online Judge Solution 1060 Positive Numbers – Solution in C, C++, Java, Python and C#

URI Online Judge Solution 1060 Positive Numbers | Beginner
URI Problem Link – https://www.urionlinejudge.com.br/judge/en/problems/view/1060

Problem Name: 1060 Positive Numbers
Problem Number : URI – 1060 Positive Numbers
Online Judge : URI Online Judge Solution

Category: Beginner
Solution Language : C,C plus plus, java, python, c#(c sharp)
Problem screenshots:

Input and output of URI 1060 problem is:

Input Sample Output Sample
7
-5
6
-3.4
4.6
12
4 valores positivos

URI 1060 Positive Numbers Code in C / URI 1060 solution in C:

#include<stdio.h>
int main()
{

double
n;
int
tmp = 0, i;

for
(i = 0; i < 6; ++i)
{

scanf("%lf", &n);
if
(n > 0){
tmp++;
}
}


printf("%i valores positivosn", tmp);

return
0;
}

Run URI 1060 Code in C language with the given input in the URI:

URI 1060 Positive Numbers Code in C++ / URI 1060 solution in CPP:

#include <cstdio>

int
main()
{

double
n;
int
tmp = 0;

for
(int i = 0; i < 6; ++i)
{

scanf("%lf", &n);
if
(n > 0)
tmp++;
}


printf("%i valores positivosn", tmp);

return
0;
}

URI 1060 Positive Numbers Code in java/ URI 1060 solution in Java:

import java.util.*;

public class
Main {
public static
void main(String args[]) {
double
n;
int
tmp = 0, i;
Scanner sc = new Scanner(System.in);

for
(i = 0; i < 6; ++i)
{

n = sc.nextDouble();
if
(n > 0){
tmp++;
}
}


System.out.printf("%d valores positivosn", tmp);
}
}

Run the URI 1060 code in a code editor realtime and must give the input given in the problem to check:

URI 1060 Positive Numbers Code in Python / URI 1060 solution in Python:

URI Solution 1060 Positive Numbers Code / URI 1060 solution in  C# (C Sharp):

Demonstration:

Just implement this in coding. Since having any problem just put a comment below. Thanks

Tags: URI Online Judge Solution, URI OJ Solution list, URI Problems Solution, URI solver, URI all problem solution list, URI 1060 Positive Numbers  code in C, URI 1060 Positive Numbers code in C++, URI 1060 Positive Numbers  solution in C, URI solution, URI 1060 solution in C,URI 1060 solution in C++-CPP,URI 1060 solution in C# (C sharp),URI 1002 solution in Java,URI 1060 Positive Numbers solution in Python,

By Maniruzzaman Akash

Maniruzzaman Akash is a freelance web developer with most popular Laravel PHP frameork and Vue JS

Leave a Reply

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