Posts

Showing posts from March, 2017

Write a program to read a line of text then count number of vowels, number of digits and number of spaces.

#include <stdio.h> int main (){ char line [ 150 ]; int i , v , c , ch , d , s , o ; o = v = c = ch = d = s = 0 ; printf ( "Enter a line of string:\n" ); gets ( line ); for ( i = 0 ; line [ i ]!= '\0' ;++ i ) { if ( line [ i ]== 'a' || line [ i ]== 'e' || line [ i ]== 'i' || line [ i ]== 'o' || line [ i ]== 'u' || line [ i ]== 'A' || line [ i ]== 'E' || line [ i ]== 'I' || line [ i ]== 'O' || line [ i ]== 'U' ) ++ v ; else if (( line [ i ]>= 'a' && line [ i ]<= 'z' ) || ( line [ i ]>= 'A' && line [ i ]<= 'Z' )) ++ c ; else if ( line [ i ]>= '0' && c <= '9' ) ++ d ; else if ( line [ i ]== ' ' ) ++ s ; } printf ( "Vowels: %d...

How do You Verify the Results of Your Search on Search Results Page?

The answer to this question is rather simple. At first instance, we need to know where the data is coming from. Are they coming from a database? Or some XML files from 3rd party websites? Once we have this information, we can start comparing the results we see on the result page with the results from the source, e.g. database. Another option is to use mocks to generate the data that we need so we can fully control the data that we see on the search results page. What is Acceptance Testing? Testing conducted to enable a user/customer to determine whether to accept a software product.Normally performed to validate the software meets a set of agreed acceptance criteria. What is Accessibility Testing? Verifying a product is accessible to the people having disabilities (deaf, blind, mentally disabled etc.). What is Adhoc Testing? A testing phase where the tester tries to ‘break’ the system by randomly trying the system’s functionality. Can include negative tes...

How do you test the login feature of a web application?

This is a very common software testing interview question and the aim is to see how broad you can think about the feature. Most interviewees start with the obvious answer of checking input fields with positive and negative values, invalid email, valid email but incorrect password, sql injection, etc. But most of these tests can be done and should be done by the developers as part of integration testing. Here the focus is on testing at system level, tests which cannot be done without a full integrated system. Answer : Possible answers to this testing interview question can be: Sign in with valid login, Close browser and reopen and see whether you are still logged in or not. Session management is important – how do we keep track of logged in users, is it via cookies or web sessions? Sign in, then logout and then go back to the login page to see if you are truly logged out. Login, then go back to the same page, do you see the login screen again? Sign in from one br...

What Test Techniques are there and what is their purpose?

Test Techniques are primarily used for two purposes: a) To help identify defects, b) To reduce the number of test cases. Equivalence partitioning is mainly used to reduce number of test cases by identifying different sets of data that are not the same and only executing one test from each set of data Boundary Value Analysis is used to check the behaviour of the system at the boundaries of allowed data. State Transition Testing is used to validate allowed and disallowed states and transitions from one state to another by various input data Pair-wise or All Pairs Testing is a very powerful test technique and is mainly used to reduce the number of test cases while increasing the coverage of feature combinations.

What is Exploratory Testing and when should it be performed?

The definition of Exploratory Testing is “simultaneous test design and execution” against an application. This means that the tester uses her domain knowledge and testing experience to predict where and under what conditions the system might behave unexpectedly. As the tester starts exploring the system, new test design ideas are thought of on the fly and executed against the software under test. On an exploratory testing session, the tester executes a chain of actions against the system, each action depends on the result of the previous action, hence the outcome of the result of the actions could influence what the tester does next, therefore the test sessions are not identical. This is in contrast to Scripted Testing where tests are designed beforehand using the requirements or design documents, usually before the system is ready and execute those exact same steps against the system in another time. Exploratory Testing is usually performed as the product is evolving (agile) o...

What is the difference between white box, black box, and gray box testing?

Usability testing is a testing methodology where the end customer is asked to use the software to see if the product is easy to use, to see the customer's perception and task time. The best way to finalize the customer point of view for usability is by using prototype or mock-up software during the initial stages. By giving the customer the prototype before the development start-up we confirm that we are not missing anything from the user point of view.

What do you mean by usability testing?

Usability testing is a testing methodology where the end customer is asked to use the software to see if the product is easy to use, to see the customer's perception and task time. The best way to finalize the customer point of view for usability is by using prototype or mock-up software during the initial stages. By giving the customer the prototype before the development start-up we confirm that we are not missing anything from the user point of view.

Describe cyclomatic complexity with example.

Cyclomatic complexity is a software metric that measure the logical strength of the program. It was developed by Thomas J. McCabe. Cyclomatic complexity is calculated by using the control flow graph of the program. In the flow graph, nodes are represented by circle. Areas bounded by edges and nodes are called regions. When counting regions, we also include the area outside the graph as a region. Complexity is computed in one of three ways: The total number of regions of the flow graph. By using the formula defined as: V(G) = E - N + 2 Cyclomatic complexity, V(G), for a flow graph, G, is also defined as V(G) = P + 1 ,where P is the number of predicate nodes contained in the flow graph G. Note: Nodes that contain a condition is called a predicate node and is characterized by two or more edges originating from it.

Important Front end Developer interview questions and answers

eneral Questions: What did you learn yesterday/this week? What excites or interests you about coding? What is a recent technical challenge you experienced and how did you solve it? What UI, Security, Performance, SEO, Maintainability or Technology considerations do you make while building a web application or site? Talk about your preferred development environment. Which version control systems are you familiar with? Can you describe your workflow when you create a web page? If you have 5 different stylesheets, how would you best integrate them into the site? Can you describe the difference between progressive enhancement and graceful degradation? How would you optimize a website's assets/resources? How many resources will a browser download from a given domain at a time? What are the exceptions? Name 3 ways to decrease page load (perceived or actual load time). If you jumped on a project and they used tabs and you used spaces, what would you do? Describe how yo...