Blog
This is my first article on this Portfolio.
A "Hello, World!" program is traditionally used to introduce novice programmers to a programming language.
"Hello, world!" is also traditionally used in a sanity test to make sure that a computer language is correctly installed, and that the operator understands how to use it.
Hey, welcome. Let me guess trying to solve the famous "Maximum Subarray Porblem ?" and came to know about Kadane's Algorithm but after trying hard couldn't figure out how something like that is working, don't worry you've come to the right place.
So, before directly jumping in the Kadane's Algo, first, you need to know about Dynamic Programming.
Those who cannot remember the past are condemned to repeat it. --Dynamic ProgrammingOver here you can find a very intuitive and detailed explaination about Dynamic Programming on GeeksforGeeks -- Dynamic Programming from GeeksforGeeks.
The task is to find a subarray (contiguous elements) of the given array that has the largest sum. For example,
[-1, -3, 4, -1, -2, 1, 5, -3]
The answer would be 7 (a subarray).[0, -1, -5, 0, -4]
The answer would be 0 and so on.
Initialize:
original_max , temporary_max = 0
Loop for each element in array:
1. temporary_max = temporary_max + A[i]
2. if (temporary_max < 0):
temporary_max = 0
3. if (original_max < temporary_max):
original_max = temporary_max
return original_max
def kadane_Algo(A):
temporary_max = original_max = A[0]
for x in A[1:]:
temporary_max = max(x, temporary_max + x)
original_max = max(original_max, temporary_max)
return original_max
original_max.
Here we are completed with the Kadane's Algorithm which is a Dynamic Programming solution to Maximum Subarray Sum Problem in runtime of O(n).
And now I insist you to go and solve this 2D Maximum Subarray Sum Problem by yourself.
Thanks for arriving here, I am Abhishek kumar Singh. And i am a pre-final year Computer Engineering Student, pursuing my degree from UNIVERSITY OF PUNE, INDIA. I should hope my work reflects that.
So, I think you guys are here because you want to know about me, HUH! Basically, I am from a small town in BIHAR, INDIA, currently living in Pune.
Franky, I am not good talking about myself but i'll start by telling you my most favourite things to do, which includes but not limited to-
I am more of a dog loving person than anything else.
Follow me @Twitter, See all my latest pics @Instagram and also look at my codes @GitHub.
Follow me @Twitter, See all my latest pics @Instagram and also look at my codes @GitHub.
And for all formal conversations, you can always shoot me a
mail.
For the web crawler two standard library are used - requests and BeautfulSoup4. requests provides a easy way to connect to world wide web and BeautifulSoup4 is used for some particular string operations.
Here this crawler collects all the product headings and respective links of the products pages from a page of amazon.in . User just need to specify what kind of data or links to be crawled.(Intially it's for title and their links)
sudo apt install python3-pippip3 install bs4python3 scraper.py
This Tourism Management Software is written in C++ programming language. Database used in this project is Files *not sql*.
| ADMIN | END-USER |
|---|---|
| Modify Packages | Select Packages |
| Modify National Destinations | Select National Destinations |
| Modify International Destinations | Select International Destinations |
| View Customer Details | Pay for Trip |