Search:

Type: Posts; User: sgk1498

Search: Search took 0.01 seconds.

  1. Replies
    2
    Views
    2,598

    C Bit Pack Function

    I'm trying run my program which is a bit packing function. However I'm experience multiple errors and looking for some insight. Thanks.



    # include "defs.h"
    # define getmask(lastbit, firstbit)...
  2. Replies
    4
    Views
    1,634

    THANK YOU! I see it!

    THANK YOU! I see it!
  3. Replies
    4
    Views
    1,634

    I changed the name of sin and the program will...

    I changed the name of sin and the program will still not run. Good catch though, I would have never thought of that.
  4. Replies
    4
    Views
    1,634

    Loop and Array Program

    I am having difficulty determining what is wrong with my code. This code is calculated the sin function without actually using the function.
    Any help or advice?


    # include <stdio.h>
    # include...
  5. Thread: Arrays in C

    by sgk1498
    Replies
    9
    Views
    2,809

    What about this for the "for" loop? #include...

    What about this for the "for" loop?


    #include <stdio.h>
    #include <stdbool.h>
    int main() {
    int i;
    int n=0;
    bool decreasing = false;
    bool increasing = false;
  6. Thread: Arrays in C

    by sgk1498
    Replies
    9
    Views
    2,809

    Yeah I'm new to C programming so if it looks like...

    Yeah I'm new to C programming so if it looks like I don't know what I'm doing that's probably because I don't...
    Thanks for your help.
  7. Thread: Arrays in C

    by sgk1498
    Replies
    9
    Views
    2,809

    How is it wrong? It compiles and tells if it...

    How is it wrong? It compiles and tells if it increasing or decreasing. it just won't tell if it is neither.
  8. Thread: Arrays in C

    by sgk1498
    Replies
    9
    Views
    2,809

    Arrays in C

    I'm trying to get this program to tell if the numbers in the array are increasing, decreasing or neither. However I can't seem to figure out how to get the program to print neither. Any suggestions?...
  9. Replies
    6
    Views
    2,600

    Thanks, I read through the section again and got...

    Thanks, I read through the section again and got a little bit better of handle on it.
    However now I am working on this.


    #include <stdio.h>
    int main(){
    int x[7] ={4,2,1,6,3,8,9};
    int...
  10. Replies
    6
    Views
    2,600

    C programming arrays

    What is printed by the following code?




    int s[4] = {9,1,2,5};
    printf("%d\n", s[4]);
  11. Replies
    5
    Views
    2,094

    #include int main() { int n, sum...

    #include <stdio.h>

    int main()
    {
    int n, sum = 0, c, value;
    scanf("%d", &c);


    for (c = 1; c != 0; c++)
    {
  12. Replies
    5
    Views
    2,094

    Sorry about that. here is what I have so far ...

    Sorry about that.
    here is what I have so far


    #include <stdio.h>

    int main()
    {
    int n, sum = 0, c, value;
    scanf("%d", &);
  13. Replies
    6
    Views
    1,514

    Thank you!

    Thank you!
  14. Replies
    6
    Views
    1,514

    I'm not quite sure how to do that. I'm new to C....

    I'm not quite sure how to do that. I'm new to C. Could you show me what you're talking about?
    Thanks
  15. Thread: Simple Loops

    by sgk1498
    Replies
    1
    Views
    2,336

    Simple Loops

    Write a program
  16. Replies
    5
    Views
    2,094

    Simple Loop Program

    3. Write a program that reads a sequence of positive integers and prints out their sum, except that if the
    same number occurs several times consecutively, ignore all but the first. Assume an input...
  17. Replies
    6
    Views
    1,514

    for #5 this is what I have so far. it is not...

    for #5 this is what I have so far.
    it is not working.



    # include <stdio.h>
    int main(){
    int a, b, i;
    scanf("%d",&a);
    scanf("%d",&b);
  18. Replies
    6
    Views
    1,514

    Simple C Program Loops

    I'm unable to find the correct way to write these loops. Could anyone help?

    5. Write a program that reads a sequence of pairs of positive integer values. For each pair, print all the
    integer...
Results 1 to 18 of 18