// editor3
#include <stdio.h>
int main(){
    int lower_bound, upper_bound;
    long long su_divisible_by_seven = 0;
    scanf("%d %d", &lower_bound, &upper_bound);
    if (lower_bound < 0 || upper_bound < 0 || lower_bound > upper_bound)
{
        printf("Invalid input\n");
        return 0;
}
for (int age = lower_bound; age <= upper_bound; age ++){
    if (age % 7 == 0){
        sum_divisible_by_seven += age;
    }
}
printf("%lld\n", sum_divisible_by_seven);
return 0;
}