Search:

Type: Posts; User: abinila

Search: Search took 0.00 seconds.

  1. Replies
    4
    Views
    1,808

    Note for above post: Before finding the...

    Note for above post:

    Before finding the position of substring we need check strstr() return value. If strstr() returns not NULL only we can find the position of the substring.
  2. Replies
    4
    Views
    1,808

    The following way will give you the correct...

    The following way will give you the correct result.



    #include <stdio.h>
    #include <string.h>
    main()
    {
    char *s1="school";
    char *s2="ool";
  3. Thread: scanf question

    by abinila
    Replies
    6
    Views
    7,613

    Try the following ways, ...

    Try the following ways,



    scanf("%[0-9]s",&s); // Read only digits.
    scanf("%[^0-9\n]s", s); // Read other than digits up to newline.


    or
  4. Replies
    12
    Views
    7,372

    Try the following algorithm for your additional...

    Try the following algorithm for your additional requirement.




    - Check the firstname whether it is a null.
    - Compare the current lastname with next record lastname .
    - The above 2 conditions...
  5. Replies
    5
    Views
    1,588

    Once we got the question from any site , we need...

    Once we got the question from any site , we need to analyze the question and answer. I think blindly no one accept the answer from any site.
  6. Replies
    3
    Views
    5,479

    I corrected your code. You made some mistakes as...

    I corrected your code. You made some mistakes as Adak said. Another one thing, You are avoiding the 0th index in an array. Is there any specific reason for this?. This is not a problem in your code....
  7. Replies
    7
    Views
    3,973

    Using stat function we can get the file type. As...

    Using stat function we can get the file type. As well as in unix we can use the stat command also.But stat command lot of situations give regular file as the type. Better we can use stat function....
  8. Replies
    5
    Views
    1,588

    Try this link. 100 Multiple choice...

    Try this link.

    100 Multiple choice questions in C
  9. Replies
    5
    Views
    6,716

    I don't know which technique you are using for...

    I don't know which technique you are using for menu selection. I will give you the two way to select the menu.In these ways there is no problem as you mentioned.

    Try this,



    main ( int argc,...
  10. structure variable

    You created the structure variable as a pointer. As a pointer it must point to a valid memory location
    You didn't assign any address to that pointer variable. So that you got an error.

    Try this,...
  11. Thread: File handling

    by abinila
    Replies
    3
    Views
    1,103

    file operation

    Try this code,




    #include <stdio.h>
    #include <stdlib.h>
    #include <string.h>

    #include <ctype.h>
Results 1 to 11 of 11