Showing posts with label software testing basic interview. Show all posts
Showing posts with label software testing basic interview. Show all posts

Building a linked list in C

In c programming, a linked list is a data structure consisting of a group of nodes which together represent a sequence. Under the simplest form, each node is composed of a data and a reference (in other words, a link) to the next node in the sequence; more complex variants add additional links. This structure allows for efficient insertion or removal of elements from any position in the sequence.
Singly-linked-list.svg
A linked list whose nodes contain two fields: an integer value and a link to the next node. The last node is linked to a terminator used to signify the end of the list.
Linked lists are among the simplest and most common data structures. They can be used to implement several other common abstract data types, including lists (the abstract data type), stacks, queues, associative arrays, and S-expressions, though it is not uncommon to implement the other data structures directly without using a list as the basis of implementation.
The principal benefit of a linked list over a conventional array is that the list elements can easily be inserted or removed without reallocation or reorganization of the entire structure because the data items need not be stored contiguously in memory or on disk. Linked lists allow insertion and removal of nodes at any point in the list, and can do so with a constant number of operations if the link previous to the link being added or removed is maintained during list traversal.
On the other hand, simple linked lists by themselves do not allow random access to the data, or any form of efficient indexing. Thus, many basic operations — such as obtaining the last node of the list (assuming that the last node is not maintained as separate node reference in the list structure), or finding a node that contains a given datum, or locating the place where a new node should be inserted — may require scanning most or all of the list elements.

 The following program shows how a simple, linear linked list can be constructed in C, using dynamic memory allocation and pointers.
#include<stdlib.h>
#include<stdio.h>

struct list_el {
   int val;
   struct list_el * next;
};

typedef struct list_el item;

void main() {
   item * curr, * head;
   int i;

   head = NULL;

   for(i=1;i<=10;i++) {
      curr = (item *)malloc(sizeof(item));
      curr->val = i;
      curr->next  = head;
      head = curr;
   }

   curr = head;

   while(curr) {
      printf("%d\n", curr->val);
      curr = curr->next ;
   }
}
www.cinterviews.com appreciates your contribution please mail us the questions you have to cinterviews.blogspot.com@gmail.com so that it will be useful to our job search community

Basic Software testing questions or Fresher QA Interview Questions

Basic Software testing questions or Fresher QA Interview Questions
1)What is the QA process?
2)How do you train another QA engineer?
3)How do you start your QA if there are no system requirements?
4)What kind of PC games you like most? Why?
5)In which Software Life cycle phase does testing occur?
6)Can you explain PDCA cycle and where does testing fit?
7)What is the difference between white box, black box and gray box testing?
8)Define Defect?
9)What is the difference between Defect and Failure?
10)What are the broader categories of defects?
11)What is the difference between Verification and Validation?
12)How does testing affect risk?
13)Does Increase in testing always mean good to the project?
14)As a manager what process did you adopt to define testing policy?
15)Should testing be only after build and execution?
16)Are number of defects more in design phase or coding phase?
17)What kind of inputs do we need from the end user to start proper testing?
18)What is the difference between Latent and Masked Defect?
19)A defect which could have been removed during initial stage is removed in later stage how does it affect cost?
20)In testing can you explain the concept of work bench?
21)
What’s the difference between Alpha and Beta testing?
22)Can you explain the concept of defect cascading?
23)Can you explain how one defect leads to other defects?
24)Can you explain what is Usability testing?
25)
What are the different strategies of rollout to the end users?
26)Can you explain requirement traceability and its importance?
27)What is the difference between Pilot and Beta testing?
28)How will you do a risk analysis during software testing?
29)How do you conclude which section is most risky in your application?
30)What does entry and exit criteria mean in a project?
31)On what basis is the Acceptance plan prepared?
32)What’s the relation between environment reality and test phases?
33)What are different types of verifications?
34)What’s the difference between Inspections and Walkthroughs?
35)Can you explain regression testing and confirmation testing?
36)what do you mean by coverage and what are the different types of coverage techniques?
37)How does fundamentally a coverage tool work?
38)What is configuration management?
39)Can you explain the concept of baseline in software development?
40)What are the different test plan documents in project?
41)How do test documents in a project span across software development life cycle?
42)Can you explain inventories?
43)How do you do Analysis and design for testing projects?
44)Can you explain calibration?
45)Which test cases are first written white boxes or black box?
46)Can you explain Co-habiting software?
47)What different impact rating’s you have used in your project?
48)Can you explain what a test log is?
49)Explain SDLC (Software development Life Cycle) in detail?
50)Can you explain waterfall model?
51)Can you explain big-bang waterfall model?
52)Can you explain phased waterfall model?
53)Explain Iterative model, Incremental model, Spiral model, Evolutionary model and V-Model?
54)Explain Unit testing, Integration tests, System testing and Acceptance testing?
55)what’s the difference between system and acceptance testing?
57)Which is the best model?
58)What group of teams can do software testing?