From 73addd2ce55263ca5324d2acebd199083c1741f4 Mon Sep 17 00:00:00 2001 From: thesaurabh4714 <42849052+thesaurabh4714@users.noreply.github.com> Date: Tue, 7 Jul 2020 01:01:50 +0530 Subject: [PATCH] Update Plus_Minus.py Fixed output format. --- HackerRank-Plus Minus/Plus_Minus.py | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/HackerRank-Plus Minus/Plus_Minus.py b/HackerRank-Plus Minus/Plus_Minus.py index 99e0b18..11f247e 100644 --- a/HackerRank-Plus Minus/Plus_Minus.py +++ b/HackerRank-Plus Minus/Plus_Minus.py @@ -18,9 +18,9 @@ def plusMinus(arr): neu+=1 else: neg+=1 - print(pos/len(arr)) - print(neg/len(arr)) - print(neu/len(arr)) + print("{:.6f}".format(pos/len(arr)) + print("{:.6f}".format(neg/len(arr)) + print("{:.6f}".format(neu/len(arr)) if __name__ == '__main__': n = int(input())