From 43ca50d6c54726b5aa30c3ab87b2c2559864bc1e Mon Sep 17 00:00:00 2001 From: karanpreet8082 Date: Sat, 19 Feb 2022 21:26:56 +0530 Subject: [PATCH 1/3] timepass --- Algorithms/Quick Sort/quicksort.py | 1 + 1 file changed, 1 insertion(+) create mode 100644 Algorithms/Quick Sort/quicksort.py diff --git a/Algorithms/Quick Sort/quicksort.py b/Algorithms/Quick Sort/quicksort.py new file mode 100644 index 0000000..e3043e6 --- /dev/null +++ b/Algorithms/Quick Sort/quicksort.py @@ -0,0 +1 @@ +print("timepass") \ No newline at end of file From 4d2b9cfd5b5a696952ad08439bc047b09f58604a Mon Sep 17 00:00:00 2001 From: karanpreet8082 Date: Sat, 19 Feb 2022 21:30:35 +0530 Subject: [PATCH 2/3] Quick sort in python --- Algorithms/Quick Sort/quicksort.py | 30 +++++++++++++++++++++++++++++- 1 file changed, 29 insertions(+), 1 deletion(-) diff --git a/Algorithms/Quick Sort/quicksort.py b/Algorithms/Quick Sort/quicksort.py index e3043e6..e406949 100644 --- a/Algorithms/Quick Sort/quicksort.py +++ b/Algorithms/Quick Sort/quicksort.py @@ -1 +1,29 @@ -print("timepass") \ No newline at end of file +# a ---> array to be sorted +# p,r ---> segment of array (sub array) being sorted +# q -----> index of the partition + +def divide(a,p,r): + k=a[r] + q=p + for i in range(p,r): + if a[i]<=k: + a[i],a[q]=a[q],a[i] + q+=1 + + a[q],a[r]=a[r],a[q] + return q + +def quick_sort(a,p,r): + if p>=r: + return + + q=divide(a,p,r) + + quick_sort(a,p,q-1) # recurse on left sub-array + quick_sort(a,q+1,r) # recurse on right sub-array + +n=int(input()) +a=list(map(int,input().split())) + +quick_sort(a,0,n-1) +print(*a) \ No newline at end of file From 7f6e114b70b4550cdaba9fb4ca9ae5c3496987e6 Mon Sep 17 00:00:00 2001 From: ok987654321 <116027569+ok987654321@users.noreply.github.com> Date: Tue, 25 Oct 2022 13:00:14 +0530 Subject: [PATCH 3/3] Create Intro.txt --- Intro.txt | 18 ++++++++++++++++++ 1 file changed, 18 insertions(+) create mode 100644 Intro.txt diff --git a/Intro.txt b/Intro.txt new file mode 100644 index 0000000..4be55e8 --- /dev/null +++ b/Intro.txt @@ -0,0 +1,18 @@ +Data is the new Oil. This statement shows how every modern IT system is driven by capturing, storing and analysing data for various needs. Be it about making decision for business, forecasting weather, studying protein structures in biology or designing a marketing campaign. All of these scenarios involve a multidisciplinary approach of using mathematical models, statistics, graphs, databases and of course the business or scientific logic behind the data analysis. So we need a programming language which can cater to all these diverse needs of data science. Python shines bright as one such language as it has numerous libraries and built in features which makes it easy to tackle the needs of Data science. + +In this tutorial we will cover these the various techniques used in data science using the Python programming language. + +Audience +This tutorial is designed for Computer Science graduates as well as Software Professionals who are willing to learn data science in simple and easy steps using Python as a programming language. + +Prerequisites +Before proceeding with this tutorial, you should have a basic knowledge of writing code in Python programming language, using any python IDE and execution of Python programs. If you are completely new to python then please refer our Python tutorial to get a sound understanding of the language. + +Execute Python Programs +For most of the examples given in this tutorial you will find Try it option, so just make use of it and enjoy your learning. + +Try following example using Try it option available at the top right corner of the below sample code box + +#!/usr/bin/python + +print "Hello, Python!"