Algorithm Design
2. T(n) represents the efficiency of the algorithm when the problem size is n. which of the following algorithms is the most efficient? A. T(n)=T(n-1)+1, T(1)=1 B. T(n)= 2n2 C. T(n)=T(n/2)+1, T(1)=1 D.T(n)=3nlogen 3. What is algorithm? What are the characteristics of algorithm? 4. Please prove that the following relationship is established: (1) 10n? – 2n= (n?) (2) 2n+1 = @(2") 5. There is an array a containing n (n>2) integers. Please design an algorithm to judge whether there are elements that appear more than half of all elements.
Algorithm Design
-
- Site Admin
- Posts: 899603
- Joined: Mon Aug 02, 2021 8:13 am