Math, asked by ajaysingh9292, 11 months ago

You are given a number n. Find the total count of set bits for all numbers from 1 to n(both inclusive).

Answers

Answered by rishika79
0

Answer:

Step-by-step explanation:

Input: n = 3

Output: 4

Input: n = 6

Output: 9

Input: n = 7

Output: 12

Input: n = 8

Output: 13

Hope it helps you....

Similar questions