Setup a Tabular View to Include Total Count of Nodes
Create two block display of a view. The view should contain All content types. displays are block_1 and block_2. set content type:Content Type A as filter criteria for block_1 and content type:Content Type B as filter criteria for block_2. so block_1 and block_2 shows all of the nodes of A and B. This link shows how to count number of results. Now the following code

&lt;?php print views_embed_view('YourView','block_1');?&gt;
&lt;?php print views_embed_view('YourView','block_2');?&gt;


outputs the number of results and you can format them in any way you want.