Demo entry 6350480

C

   

Submitted by anonymous on Mar 11, 2017 at 04:41
Language: C. Code size: 479 Bytes.

int main()
{
	int remaining_UL_resource=10;
	std::list<UL_UE_list> o;
	int index[10] = { 3, 1, 7, 4, 2, 1, 9, 7, 2, 1};
	int cnt = 0;

	for (int i = 0; i < 10; ++i)
	{
		do_NPUSCH_Resource_Allocation(remaining_UL_resource);
		UL_UE_list a;
		a.DV = index[i];
		o.push_back(a);
		++remaining_UL_resource;
	}

	o.sort(compareMyType);

	for (std::list<UL_UE_list>::iterator i = o.begin(); i != o.end(); ++i)
		std::cout << (&*i)->DV << std::endl;

	return 0;
}

This snippet took 0.01 seconds to highlight.

Back to the Entry List or Home.

Delete this entry (admin only).