首页 > 代码库 > 最大子序列和

最大子序列和

#include <stdio.h>
#include <stdlib.h>

int main()
{
	int this_sum, max_sum, old_first, old_last, new_first;
	int n,i, tmp, flag = 1;
	int first = 1;
	int *data;
	
	scanf("%d", &n);
	this_sum= max_sum = old_first = new_first = 0;
	old_last = n - 1;
		
	data = http://www.mamicode.com/(int *)malloc(n * sizeof(int));>

最大子序列和