How many bytes are used to store a 64-bit number?
how many bytes are there in a 64-bit machine?
Another Answer:
It takes 8 bytes to store a 64 bit number.
Turbo c program that will determine if the input is odd or even number?
#include <stdio.h>
int main()
{
printf("Program to find ODD or Even Number\n");
while(1)
{
int n = 0;
printf("\nEnter a number(-1 for Exit): ");
scanf("%d",&n);
if( n 0)
{
printf("%d is a EVEN number.\n", n);
}
else
{
printf("%d is a ODD number.\n", n);
}
}
return 0;
}
What is flowchart of stack using array in c prog?
Two little problems:
1. stack doesn't have a flow-chart
2. there are no flow-charts in a C program
What is the built in function to draw lines in Visual C plus plus?
C++ has no built-in function to draw lines, nor indeed to perform any type of graphics output. The standard library is designed to be as generic as possible, and is therefore capable of supporting all platforms using text output only. Graphics output is obviously possible, but it is platform-specific so you will need a graphics API that provides functions that are specific to your operating system and/or hardware.
What is a interpretive statement?
An interpretive statement is basically a claim that you have written that connects to the central idea of yo stupid essay
CPD
In pointers to store float address is we can use integer variable?
You can't address memory with floating point values. All pointers are integer values pointing to a location in memory, regardless of what type it is pointing to. If you wanted a floating point pointer, then the following should do the trick:
float *floatingPointer;
Note: If you wanted to ask that which integer type is big enough to hold a (flat) pointer, then the answer: ptrdiff_t, intptr_t (both signed) and size_t, uintptr_t (both unsigned).
How do you declare an N-Dimensional array using Malloc?
#include <stdlib.h>
int **array1 = malloc(nrows * sizeof(int *));
for(i = 0; i < nrows; i++)
array1[i] = malloc(ncolumns * sizeof(int));
How do you draw a perfect circle?
Get a cup or bottle somethig round orrr... you can stick a hole in the middle with a thumbtack in it with string on the thubtack conected to the pen (or pencil) and go around:)
How records are logically deleted from files?
You might define a boolean field in the record meaning 'this record is logically deleted: yes/no'.
How would you read int const p?
int const *p declares a 'p' pointer, that points to a constant integer
What is an algorithm to evaluate prefix expression using stack with example?
I HOPE THIS WILL HELP U OUT...
ALGO GOES LIKE THIS: Reverrse prreffiix and evalluatte iitt
reverse given prefix expression;
scan the reversed prefix expression;
for each symbol in reversed prefix
if operand then
push its value onto stack S;
if operator then {
pop operand1;
pop operand2;
compute result = operand1 op operand2;
push result back onto stack S;
}
return value at top of stack;
AND EXAMPLE IS:Prefix: */-abc-+def Reversed: fed+-cba-/*
ch action stack
f push f
e push f e
d push f e d
+ pop op1 f e
pop op2 f
calc &push f (d+e)
- pop op1 f
pop op2
calc & push ((d+e)-f)
c push ((d+e)-f) c
b push ((d+e)-f) c b
a push ((d+e)-f) c b a
- pop op1 ((d+e)-f) c b
pop op2 ((d+e)-f) c
calc & push ((d+e)-f) c (a-b)
ch action stack
/ pop op1 ((d+e)-f) c
pop op2 ((d+e)-f)
calc & push ((d+e)-f) ((a-b)/c)
* pop op1 ((d+e)-f)
pop op2
calc & push ((a-b)/c)*((d+e)-f)
C plus plus for while loop example code?
The syntax for a for loop is:
for (initialization; condition; increase) {
statement;
}
for example:
int arr[5] = {1, 2, 3, 4, 5};
for (int i = 0; i < 5; i++) {
cout << arr[i] << endl;
// you can do alot more in a for loop than just print to console
}
while loop syntax
while (condition) {
// statements
}
example:
int i = 0;
// the loop will end when i = 5
// unlike for loop you must increment variables yourself or
// use the break command to exit the loop
while (i != 5) {
cout << i << endl;
i++;
}
What is a quick way to factor an equation in the form of ax squared plus bx plus c?
== == == ==
* Yahoo! * My Yahoo! * Mail * More Yahoo! Services ** News ** Sports ** Finance ** Entertainment Get Yahoo! Toolbar MakeY!My HomepageGet Yahoo! Toolbar
New User? Sign UpSign InHelp
Yahoo! Searchweb search
* Ask * Answer * Discover
Search for questions: Advanced SearchMy Profile
# Home > # Science & Mathematics > # Mathematics > # Open Question itguru53... ; Member since: : August 20, 2006 ; Total points: : 1247 (Level 3) * Add to My Contacts * Block User
Show me another » = Quick way to factor this polynomial? = 2x^2 + 5x - 33 = 0
What are some quick ways to factor this without listing all possible combinations? * 3 days ago * - 1 day left to answer. Answer Question
Report Abuse
* 0 stars - mark this as Interesting! Be the first person to mark this question as interesting!
* Email * Save ** Add to private Watchlist ** Save to Yahoo! Bookmarks ** Add to My Yahoo! ** Add to Del.icio.us ** RSS
Show:All AnswersOldest to NewestNewest to OldestRated Highest to Lowest
* by dan131m *; Member since: *: December 07, 2007 *; Total points: *: 7690 (Level 5) ** Add to My Contacts ** Block User
Quadratic formula / completing the square ** 3 days ago ** 0 Rating: Good Answer ** 0 Rating: Bad Answer ** Report Abuse
* by Mark *; Member since: *: January 30, 2008 *; Total points: *: 6908 (Level 5) *; Badge Image: *: *; Contributing In: *: Mathematics ** Add to My Contacts ** Block User
(2x + 11)(x - 3)
There are only two combinations: 1 and 33 or 3 and 11. Only one way to get a 2 (1)(2)
You start with (2x + __)( x - __)
Now use logic. Since 5 is small, you need two factrs of 33 that are fairly close, namely 3 and 11 (closer that 1 and 33). Done. ** 3 days ago ** 0 Rating: Good Answer ** 0 Rating: Bad Answer ** Report Abuse
* by RichardH *; Member since: *: April 27, 2009 *; Total points: *: 4291 (Level 4) ** Add to My Contacts ** Block User
Sure the key is the b term +5. Your job is to separate the factors of 33 in such a way that 2 times one factor yields a difference of 5 whan the "i" & "o" terms are added together. Sooo, 3+11 seem to do the trick
(2x+11)(x-3)=0 ** 3 days ago ** 0 Rating: Good Answer ** 0 Rating: Bad Answer ** Report Abuse
* by norman *; Member since: *: August 26, 2007 *; Total points: *: 24514 (Level 6) *; Badge Image: *: *; Contributing In: *: Mathematics ** Add to My Contacts ** Block User
use the quad formula
x = (-5 +/- sqrt(25 + 264))/4 = (-5+/- 17)/4 = -11/2 or 3
listing the factor of 66 is just as easy in this case, -6 +11
(2x +11)(x - 3) = 0
x = -11/2 or 3 ** 3 days ago ** 0 Rating: Good Answer ** 0 Rating: Bad Answer ** Report Abuse
* by Pothana *; Member since: *: August 14, 2009 *; Total points: *: 119 (Level 1) ** Add to My Contacts ** Block User
2x^2 + 5x - 33 = 0
What I do is:
- Make a big 'X'
- On the top, write '-66' [co-efficient of 'x^2' multiplied by the last number]
- On the bottom, write '5' [co-efficient of 'x']
- Now... Find two numbers that multiply to -66 and add to 5
Numbers: 11 and -6
Now re-write the question as:
2x^2 -6x + 11x - 33 = 0 [Take '2x' common; Take '11' common]
2x(x - 3) + 11(x - 3) = 0 [Take '(x - 3)' common]
(x - 3) (2x + 11) = 0
Now... Solve for 'x'
Make two different equations --
(x - 3) = 0 and (2x + 11) = 0
First equation --
(x - 3) = 0
x - 3 = 0
x = 3 [One answer]
Second equation --
(2x + 11) = 0
2x + 11 = 0
2x = -11
x = -11/2 [Second answer]
Answers:
x = 3
x = -11/2 My work ** 3 days ago ** 0 Rating: Good Answer ** 0 Rating: Bad Answer ** Report Abuse
* by Basanta *; Member since: *: August 08, 2009 *; Total points: *: 91 (Level 1) ** Add to My Contacts ** Block User
2x^2+11x -6x-33=0 :x[2x+11]-3[2x+11]=0 ;[x-3][2x+11]=0 x-3=0 and2x+11=0 x=3 and x=-11/2 ** 3 days ago ** 0 Rating: Good Answer ** 0 Rating: Bad Answer ** Report Abuse
* by Jun Agruda *; Member since: *: May 17, 2007 *; Total points: *: 82867 (Level 7) *; Badge Image: *: *; Contributing In: *: Mathematics ** Add to My Contacts ** Block User ** Best answer 25% ** 17401 answers *; Badge Image: *: *; Contributing In: *: Mathematics *; Member Since: *: May 17, 2007 *; Total Points: *: 82867 (Level 7) *; Points earned this week: *: 39
** Add to My Contacts ** Block User
2x² + 5x - 33 = 0
2x² + 5x = 33
x² + 5/2x = 33/2
x² + 5/4x = 33/2 + (5/4)²
x² + 5/4x = 264/16 + 25/16
(x + 5/4)² = 289/16
x + 5/4 = ± 17/4
Factors starting from the last line above:
= x + 5/4 - 17/4, = x - 12/4, = x - 3
= x + 5/4 + 17/4, = x + 22/4, = x + 11/2, = 2x + 11
Answer: (x - 3)(2x + 11)-there's no shorter way I could think of.
Proof:
= (x - 3)(2x + 11)
= x(2x) + x(11) - 3(2x) - 3(11)
= 2x² + 11x - 6x - 33
= 2x² + 5x - 33 ** 2 days ago ** 0 Rating: Good Answer ** 0 Rating: Bad Answer ** Report Abuse
Graphical Prime Factorization
Wednesday, July 20th, 2005 Every so often I like to waste a lot of time trying to solve some practically impossible math problem, like finding a simple proof to Fermat's Last Theorem or proving Goldbach's Conjecture. These days I'm trying to find a quick way to factor numbers by using graphs to gain insights. (Unlike the other problems, solving this one would put me in an interesting dilemma about how to publish the solution.)Trial division is the most basic technique for factoring numbers. You just go through candidate factors, dividing each one into the number to be factored and getting a yes/no for each candidate. My thought was to look at the result of the division (not just yes/no) and use that to decide how far to skip ahead for selecting the next candidate. The first graph shows trial divisions of the number 3341287, which is the product of two primes, 2087 and 1601. The candidate factors start at the square root of n and increase along the horizontal axis. The remainders are on the vertical axis. You can definitely see patterns in the remainders, and it turns out the points lie on "concentric" quadratic curves. The equations for the curves are all of the form: x^2 - m*x + n, for some integer m. We can factor the quadratic into (x-a)(x-b) where n=ab and m=a+b, but that doesn't help since n=ab is what we're trying to solve in the first place. However, since each curve covers multiple points, we can reduce our work by iterating over m and solving each quadratic instead of iterating over each x. Unfortunately successive curves cover fewer and fewer factors, and soon it doesn't help at all. We might also try to solve the general quadratic. Using the quadratic formula we end up with something of the format k^2-n under the radical (where 2k=m), which means all we have to do is find a k that makes the square root an integer, or in other words an integer solution to k^2 - n = p^2, or k^2 - p^2 = n, or (k-p)(k+p) = n, but then we're back where we started trying to factor n. The second graph is the same as the first, but with a wider domain of x. Other interesting quadratics start to appear. In all graphs the red line represents y=x. The technique of using the quadratics to skip candidates is basically the same as Fermat's factorization method, except with a graphically inspired derivation. Fermat started where I ended, noticing that any odd number could be written as (k-p)(k+p) and then trying to find solutions by starting k at the square root of n and checking if each k^2 - n is a perfect square. The last graph shows the remainders for the x values corresponding to the Fermat trial divisors. I think each "Fermat point" represents a quadratic curve from above, using the point with the maximum remainder (or 0 remainder). The green line is at y=n/x, and I'm not sure why all the non-trivial Fermat remainders are above it. So iterating through quadratics is really the same as Fermat's method, and we haven't gained anything, but what about the patterns in the Fermat remainders themselves? Looks like there are some quadratics there as well and maybe we can use the same idea to reduce the number of Fermat points we examine. I've found that the quadratics are generally of the form x^2 - a/b * x + n/b, where b has been a small integer in my tests. I haven't gone much further - there needs to be a way of iterating through these quadratics with confidence of convering all the candidate factors. Then again, even if only most of the candidates are covered, there's some chance of finding a factor quicker. At best, any attempt to use those quadratics will surely also be duplicating optimizations that have already be made to Fermat's method. For instance, there is a method of re-centering the search by multiplying n by some number to offset the problem of diminishing returns once you get far from the "center", and that sounds a lot like using the quadratics that have another center point.
How do you type c with accent?
Use charmap.exe, (you can use these characters: ĆĈĊČ, and many others)