answersLogoWhite

0

HCF and LCM of p and p plus 1?

Updated: 9/16/2023
User Avatar

Wiki User

12y ago

Best Answer

To consecutive numbers cannot have any common prime factors. Thus the HCF of p and (p+1) will be 1. To find the LCM, you multiply two numbers together and divide by the HCF. In this case, you'd do p(p+1)/1

This simplifies to p2+p

So the HCF is 1 and the LCM is p2+p

User Avatar

Wiki User

12y ago
This answer is:
User Avatar

Add your answer:

Earn +20 pts
Q: HCF and LCM of p and p plus 1?
Write your answer...
Submit
Still have questions?
magnify glass
imp
Continue Learning about Math & Arithmetic

Write a program that accepts 15 different numbers and find the LCM and HCM?

/* Program to find LCM/HCF of 15 Nos in C++/ C (replace cin with scanf & cout with printf for c) */ /* Developed by - Kishore Kr. Banerjee - papillon_kish@yahoo.com */ #include <iostream.h> #include <conio.h> main() { int num[3],i,j,p,q,tmp,n1,n2,LCM,rem,flag; clrscr(); for(i=0;i<3;i=i+1) { cout<<"Enter No - "<<i+1<<"="; cin>>num[i]; } clrscr(); n1=num[0]; p=n1; for(i=1;i<3;i=i+1) { n2=num[i]; /* Finding HCF */ q=n2; if(p<q) { tmp=q; q=p; p=tmp; } while(p%q!=0) { rem=p%q; q=p; p=rem; if(p<q) { tmp=q; q=p; p=tmp; } } /*finding LCM */ LCM=1; for(j=1;n1%j==0n2%j==0;j=j+1) { if(n1%j==0) { n1=n1/j; flag=1; } if(n2%j==0) { n2=n2/j; flag=1; } if(flag==1) { LCM=LCM*j; } } LCM=LCM*n1*n2; n1=LCM; } cout<<"the LCM ="<<LCM; cout<<"the hcf ="<<q; getch(); } ----- int gcd (int a, int b) { . int tmp; . if (a<0) a= -a; . if (b<0) b= -b; . if (a<b) tmp= a, a= b, b= tmp; . while (b) { . . tmp= a%b; . . a= b; . . b= tmp; . } . return a; } int gcd_n (int n, const int *vect) { . int i, gcdtmp; . for (i=0, gcdtmp=0; i<n && gcdtmp!=1; ++i) . . gcdtmp= gcd (gcdtmp, vect[i]); . return gcdtmp; } int LCM (int a, int b) { . int d= gcd (a, b); . if (d==0) return d; . else return a/d*b; } int lcm_n (int n, const int *vect) { . int i, lcmtmp; . for (i=0, lcmtmp=1; i<n; ++i) . . lcmtmp= LCM (lcmtmp, vect[i]); . return lcmtmp; }


What is 6p plus 1 equals p plus 21?

p = 4


P -1 equals 5p plus 3p - 8?

p=1


If p and q are positive integers and 1 plus p plus q plus pq 14 what is the value of pq?

6


Can you answer this 6 equals p-17 plus 1?

6 = p - 17 + 1-------------------5 = p - 17-------------------p = 22

Related questions

C program that accepts 15 different numbers and find the HCF and LCM?

#include <iostream.h> #include <conio.h> main() { int num[3],i,j,p,q,tmp,n1,n2,LCM,rem,flag; clrscr(); for(i=0;i<3;i=i+1) { cout<<"Enter No - "<<i+1<<"="; cin>>num[i]; } clrscr(); n1=num[0]; p=n1; for(i=1;i<3;i=i+1) { n2=num[i]; /* Finding HCF */ q=n2; if(p<q) { tmp=q; q=p; p=tmp; } while(p%q!=0) { rem=p%q; q=p; p=rem; if(p<q) { tmp=q; q=p; p=tmp; } } /*finding LCM */ LCM=1; for(j=1;n1%j==0n2%j==0;j=j+1) { if(n1%j==0) { n1=n1/j; flag=1; } if(n2%j==0) { n2=n2/j; flag=1; } if(flag==1) { LCM=LCM*j; } } LCM=LCM*n1*n2; n1=LCM; } cout<<"the LCM ="<<LCM; cout<<"the hcf ="<<q; getch(); } ----- int gcd (int a, int b) { . int tmp; . if (a<0) a= -a; . if (b<0) b= -b; . if (a<b) tmp= a, a= b, b= tmp; . while (b) { . . tmp= a%b; . . a= b; . . b= tmp; . } . return a; } int gcd_n (int n, const int *vect) { . int i, gcdtmp; . for (i=0, gcdtmp=0; i<n && gcdtmp!=1; ++i) . . gcdtmp= gcd (gcdtmp, vect[i]); . return gcdtmp; } int LCM (int a, int b) { . int d= gcd (a, b); . if (d==0) return d; . else return a/d*b; } int lcm_n (int n, const int *vect) { . int i, lcmtmp; . for (i=0, lcmtmp=1; i<n; ++i) . . lcmtmp= LCM (lcmtmp, vect[i]); . return lcmtmp; }


Can any number have 15 as their HCF and 175 as their LCM?

No.-------------------------------------------------------------To find the HCF and LCM of two (or more) numbers list the numbers in their prime factorisations in power format; then:HCF = product of the primes to the LOWEST power across all the numbers;LCM = product of the primes to the HIGHEST power across all the numbers.Note: for p being any prime, p⁰ = 1; so if a prime does not appear as a factor of a number, it can be said to have a power of 0. This means that the LOWEST power is 0 and the prime does not appear in the HCF of the numbers. The HIGHEST power of a prime must be at least the LOWEST power of a prime.Thus if a prime appears in the HCF of the numbers (with a power greater than or equal to 1) it MUST also appear in the LCM of the numbers.If the HCF of some numbers is 15, then: 15 = 3 × 5 which means that the primes 3 and 5 MUST both apear in the LCM.But 175 = 5² × 7, which does NOT include 3, so 175 CANNOT be the LCM of some numbers which have a HCF of 15.


Write a program that accepts 15 different numbers and find the LCM and HCM?

/* Program to find LCM/HCF of 15 Nos in C++/ C (replace cin with scanf & cout with printf for c) */ /* Developed by - Kishore Kr. Banerjee - papillon_kish@yahoo.com */ #include <iostream.h> #include <conio.h> main() { int num[3],i,j,p,q,tmp,n1,n2,LCM,rem,flag; clrscr(); for(i=0;i<3;i=i+1) { cout<<"Enter No - "<<i+1<<"="; cin>>num[i]; } clrscr(); n1=num[0]; p=n1; for(i=1;i<3;i=i+1) { n2=num[i]; /* Finding HCF */ q=n2; if(p<q) { tmp=q; q=p; p=tmp; } while(p%q!=0) { rem=p%q; q=p; p=rem; if(p<q) { tmp=q; q=p; p=tmp; } } /*finding LCM */ LCM=1; for(j=1;n1%j==0n2%j==0;j=j+1) { if(n1%j==0) { n1=n1/j; flag=1; } if(n2%j==0) { n2=n2/j; flag=1; } if(flag==1) { LCM=LCM*j; } } LCM=LCM*n1*n2; n1=LCM; } cout<<"the LCM ="<<LCM; cout<<"the hcf ="<<q; getch(); } ----- int gcd (int a, int b) { . int tmp; . if (a<0) a= -a; . if (b<0) b= -b; . if (a<b) tmp= a, a= b, b= tmp; . while (b) { . . tmp= a%b; . . a= b; . . b= tmp; . } . return a; } int gcd_n (int n, const int *vect) { . int i, gcdtmp; . for (i=0, gcdtmp=0; i<n && gcdtmp!=1; ++i) . . gcdtmp= gcd (gcdtmp, vect[i]); . return gcdtmp; } int LCM (int a, int b) { . int d= gcd (a, b); . if (d==0) return d; . else return a/d*b; } int lcm_n (int n, const int *vect) { . int i, lcmtmp; . for (i=0, lcmtmp=1; i<n; ++i) . . lcmtmp= LCM (lcmtmp, vect[i]); . return lcmtmp; }


Shell script to find LCM of the given two numbers?

Shell program to find LCM and hcf of two no.s tput clear echo "Enter first no" read a echo "Enter 2nd no" read b p= 'expr $a \* $b' while [$b -ne 0] do r= 'expr $a % $b' a=$b b=$r done LCM = 'expr $p / $a' echo "LCM = $LCM" echo "Hcf = $a"


What is the GCF and LCM of the following numbers where p q and r are distinct primes?

The GCF is 1. The LCM is p x q x r.


How do you get the simplest form?

To find the simplest form of the fraction p/q first find the highers common factor of p and q. If HCF(p, q) = 1 then the fraction is already in its simplest form and there is nothing to be done. Otherwise, divide p by the HCF to give r, divide q by HCF to give s and the simplest form is r/s.


What is 6p plus 1 equals p plus 21?

p = 4


If SinA plus sinp plus sinX 3 then show that A plus P plus X 270?

take A=1,P=1X=1 1+1+1=3 sin 90=1, a+p+x 90+90+90=270


P -1 equals 5p plus 3p - 8?

p=1


What is the value of p 5(p plus 6)25?

If 5*(p + 6) = 25 then p is -1


If p and q are positive integers and 1 plus p plus q plus pq 14 what is the value of pq?

6


What is the value of p in this equation 45 plus (p plus 3 12) (45 plus 15) plus 3 12?

1/5